/* 
 * Alignment Fix CSS
 * Addresses overall website alignment issues with award-winning UX standards
 */

/* ===== Global Container Fixes ===== */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

/* Ensure consistent section spacing */
section {
  padding: 60px 0;
  overflow: hidden; /* Prevent horizontal overflow */
  position: relative;
}

/* Proper content alignment */
.row {
  display: flex;
  flex-wrap: wrap;
  margin: 0 -15px;
}

.col-md-4, .col-md-6, .col-md-8, .col-md-12 {
  padding: 0 15px;
  width: 100%;
  box-sizing: border-box;
}

/* ===== Mobile Alignment Fixes ===== */
@media (max-width: 991px) {
  /* Proper mobile container padding */
  .container {
    padding: 0 15px;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }
  
  /* Reduced section padding on mobile */
  section {
    padding: 40px 0;
    width: 100%;
    overflow-x: hidden;
  }
  
  /* Center align text on mobile */
  .text-center-mobile {
    text-align: center;
  }
  
  /* Ensure images don't overflow */
  img {
    max-width: 100%;
    height: auto;
  }
  
  /* Fix hero section alignment */
  #hero .container {
    padding: 0 15px;
  }
  
  /* Fix services section alignment */
  #services .container {
    padding: 0 15px;
    overflow: hidden;
  }
  
  /* Ensure content doesn't create horizontal scroll */
  .row {
    margin: 0;
    width: 100%;
  }
}

/* ===== Header Alignment Fixes ===== */
#header .container {
  padding: 0 15px;
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

/* ===== Hero Section Alignment ===== */
#hero .container {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  padding: 0;
}

.hero-content {
  width: 100%;
  max-width: 650px;
  margin: 0 auto;
  text-align: center;
  padding: 0 20px;
}

/* Fix hero slider alignment */
.hero-slider {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

.hero-slide {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ===== Services Section Alignment ===== */
#services .container {
  overflow: hidden;
  max-width: 100%;
}

/* Fix services row alignment */
.services-row {
  width: 100%;
  max-width: 100%;
  padding-left: 15px;
  padding-right: 15px;
  margin: 0 auto;
  box-sizing: border-box;
}

/* Fix service card alignment */
.service-card {
  margin: 0 5px;
  box-sizing: border-box;
}

/* Fix service content alignment */
.service-content {
  width: calc(100% - 30px);
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

/* ===== Testimonials Alignment ===== */
.testimonial-slider {
  overflow: hidden;
  width: 100%;
}

/* ===== Contact Section Alignment ===== */
.contact-info {
  margin-bottom: 30px;
}

/* ===== Footer Alignment ===== */
footer .container {
  text-align: center;
}

/* ===== Button Alignment ===== */
.btn-wrapper {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 20px 0;
}

/* ===== Image Alignment ===== */
.image-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.image-wrapper img {
  max-width: 100%;
  height: auto;
  object-fit: cover;
}

/* ===== Text Alignment ===== */
.section-header {
  text-align: center;
  margin-bottom: 40px;
}

/* ===== Form Alignment ===== */
form {
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
}

/* ===== Responsive Fixes ===== */
@media (min-width: 768px) {
  .col-md-4 {
    width: 33.333333%;
  }
  
  .col-md-6 {
    width: 50%;
  }
  
  .col-md-8 {
    width: 66.666667%;
  }
}

/* ===== Fix for horizontal overflow ===== */
body {
  overflow-x: hidden;
  width: 100%;
  position: relative;
}

html {
  overflow-x: hidden;
}
