/* ===== Industries Page Styles ===== */

/* Industries Hero Section */
.industries-hero {
  background: var(--jm-color-primary);
  color: white;
  padding: 100px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.industries-hero::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('../img/banner-1.jpg') no-repeat center center;
  background-size: cover;
  opacity: 0.2;
  z-index: 0;
}

.industries-hero .home-inner {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.industries-hero h1 {
  font-size: 48px;
  margin-bottom: 20px;
  color: white;
  font-weight: 700;
  line-height: 1.2;
}

.industries-hero p {
  font-size: 18px;
  max-width: 800px;
  margin: 0 auto;
  color: rgba(255, 255, 255, 0.9);
}

/* Industries Overview Section */
.industries-overview {
  padding: 60px 0;
  background: white;
}

.industries-overview .home-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  text-align: center;
}

.industries-overview h2 {
  font-size: 36px;
  margin-bottom: 20px;
  color: var(--jm-color-primary);
  font-weight: 700;
}

.industries-overview p {
  font-size: 17px;
  max-width: 900px;
  margin: 0 auto;
  color: var(--jm-color-text);
  line-height: 1.8;
}

/* Industries Grid Section */
.industries-grid {
  padding: 80px 0;
  background: #f8fafc;
}

.industries-grid .home-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, max(350px, calc(33.333% - 20px))));
  gap: 30px;
  justify-content: center;
}

/* Industry Item */
.industry-item {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
  transition: all 0.3s ease;
  height: 100%;
}

.industry-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.industry-image {
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f5f9;
  height: 200px;
}

.industry-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.industry-item:hover .industry-image img {
  transform: scale(1.05);
}

/* Case Studies Pagination */
.case-studies-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  margin-top: 60px;
  padding: 20px 0;
  grid-column: 1 / -1;
}

.pagination-button {
  background: var(--jm-color-primary);
  color: white;
  border: none;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.pagination-button:hover:not(:disabled) {
  background: var(--jm-color-primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.pagination-button:disabled {
  background: #ccc;
  cursor: not-allowed;
  transform: none;
}

.pagination-info {
  font-size: 16px;
  color: #666;
  font-weight: 500;
}

/* Ensure case studies grid doesn't stretch with pagination */
.case-studies-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(350px, max(350px, calc(33.333% - 20px))));
  gap: 30px;
  justify-content: center;
  width: 100%;
  box-sizing: border-box;
}

/* Ensure industries-grid also uses 3 columns */
.industries-grid .home-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  box-sizing: border-box;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .case-studies-grid {
    grid-template-columns: repeat(2, minmax(300px, max(300px, calc(50% - 15px))));
    gap: 20px;
  }
}

@media (max-width: 768px) {
  /* Reset container styles for mobile */
  .industries-grid {
    padding: 0;
  }
  
  .industries-grid .home-inner {
    padding: 0 10px;
    max-width: 100%;
  }
  
  /* Adjust case studies grid for mobile */
  .case-studies-grid {
    grid-template-columns: 1fr;
    gap: 20px;
    max-width: 100%;
    margin: 0;
    width: 100%;
  }
  
  /* Optimize case study items for mobile */
  .industry-item {
    margin: 0 auto;
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
  }
  
  /* Adjust image size for mobile */
  .industry-image {
    height: 250px;
  }
  
  /* Adjust content padding for mobile */
  .industry-content {
    padding: 20px;
  }
  
  /* Adjust typography for mobile */
  .industries-hero h1 {
    font-size: 36px;
  }
  
  .industry-content h3 {
    font-size: 20px;
  }
  
  /* Adjust pagination for mobile */
  .case-studies-pagination {
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 40px;
    padding: 0 10px;
  }
  
  .pagination-button {
    padding: 10px 16px;
    font-size: 14px;
  }
}

/* Ensure images scale properly */
.industry-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Ensure home-inner doesn't restrict mobile width */
@media (max-width: 768px) {
  .home-inner {
    padding-left: 10px;
    padding-right: 10px;
    max-width: 100%;
    width: 100%;
  }
}

/* Fix container width issues */
.industries-overview .home-inner {
  padding: 0 20px;
}

@media (max-width: 768px) {
  .industries-overview .home-inner {
    padding: 0 10px;
  }
  
  .industries-hero .home-inner {
    padding: 0 10px;
  }
}

/* Base styles for industry content */
.industry-content {
  display: flex;
  flex-direction: column;
  gap: 15px;
  flex-grow: 1;
  padding: 30px;
}

.industry-content h3 {
  font-size: 22px;
  color: var(--jm-color-primary);
  font-weight: 700;
  margin: 0;
}

/* Ensure case studies grid is properly centered */
.industries-grid {
  padding: 40px 0;
}

/* Ensure cards don't overflow on mobile */
.industry-item {
  box-sizing: border-box;
  width: 100%;
}

.industry-content p {
  font-size: 15px;
  color: var(--jm-color-text);
  line-height: 1.6;
  margin: 0;
  flex-grow: 1;
}

.industry-content ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.industry-content li {
  font-size: 14px;
  color: var(--jm-color-text);
  position: relative;
  padding-left: 20px;
}

.industry-content li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--jm-color-accent);
  font-weight: bold;
  font-size: 16px;
}

.industry-content a {
  display: inline-block;
  margin-top: 10px;
  color: var(--jm-color-primary);
  font-weight: 600;
  text-decoration: none;
  transition: color 0.3s ease;
  font-size: 14px;
}

.industry-content a:hover {
  color: var(--jm-color-accent);
}

/* CTA Section */
.home-cta {
  background: var(--jm-color-primary);
  color: white;
  padding: 100px 0;
  text-align: center;
}

.home-cta .home-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.home-cta h2 {
  font-size: 40px;
  margin-bottom: 20px;
  color: white;
  font-weight: 700;
}

.home-cta p {
  font-size: 18px;
  max-width: 800px;
  margin: 0 auto 35px;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.8;
}

.home-cta a {
  display: inline-block;
  padding: 16px 40px;
  background: var(--jm-color-accent);
  color: white;
  text-decoration: none;
  border-radius: 6px;
  font-weight: 600;
  transition: all 0.3s ease;
  border: 2px solid var(--jm-color-accent);
}

.home-cta a:hover {
  background: transparent;
  border-color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .industries-grid .home-inner {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
  }
  
  .industry-image {
    height: 180px;
  }
  
  .industries-hero h1 {
    font-size: 36px;
  }
  
  .industries-overview h2 {
    font-size: 30px;
  }
}

@media (max-width: 768px) {
  .industries-hero {
    padding: 80px 0;
  }
  
  .industries-overview {
    padding: 40px 0;
  }
  
  .industries-grid {
    padding: 60px 0;
  }
  
  .industries-grid .home-inner {
    grid-template-columns: 1fr;
    gap: 20px;
    padding: 0 16px;
  }
  
  .industry-image {
    height: 160px;
  }
  
  .home-cta {
    padding: 80px 0;
  }
  
  .home-cta h2 {
    font-size: 32px;
  }
  
  .industry-content {
    padding: 24px;
  }
  
  .industry-content h3 {
    font-size: 20px;
  }
}

@media (max-width: 480px) {
  .industries-hero h1 {
    font-size: 28px;
  }
  
  .industries-hero p {
    font-size: 16px;
  }
  
  .industries-overview h2 {
    font-size: 24px;
  }
  
  .industries-grid .home-inner {
    padding: 0 12px;
    gap: 18px;
  }
  
  .industry-image {
    height: 150px;
  }
  
  .industry-content {
    padding: 20px;
    gap: 12px;
  }
  
  .industry-content h3 {
    font-size: 18px;
  }
  
  .industry-content p {
    font-size: 14px;
  }
  
  .industry-content li {
    font-size: 13px;
    padding-left: 18px;
  }
  
  .home-cta h2 {
    font-size: 28px;
  }
  
  .home-cta p {
    font-size: 16px;
  }
  
  .home-cta a {
    padding: 14px 32px;
    font-size: 15px;
  }
}
