/* Main Section Styling */

.legal-services {
    background-image: url('https://allimgb.ams3.cdn.digitaloceanspaces.com/lawfirm/domain_bacl1.webp');
    background-size: cover;
    background-position: center;
    padding: 80px;
    color: white;
    text-align: center;
    margin-top: 80px;
  }

.legal-services h2 {
    font-size: 2rem;
    margin-bottom: 20px;
    color: #c99200
  }

.legal-services p {
    color: black;
    font-size: 1.2rem;
    max-width: 80%;
    margin: 0 auto;
    text-align: justify;  /* Justify the text */
  }

#dintev-article:nth-child(1) {
    background-image: url('https://allimgb.ams3.cdn.digitaloceanspaces.com/lawfirm/Alpha1.webp');
}

#dintev-article:nth-child(2) {
    background-image: url('https://allimgb.ams3.cdn.digitaloceanspaces.com/lawfirm/Alpha2.webp');
}

#dintev-article:nth-child(3) {
    background-image: url('https://allimgb.ams3.cdn.digitaloceanspaces.com/lawfirm/Alpha3.webp');
}

/* Content inside articles (text, CTA, etc.) */
#dintev-article .content {
    position: relative;
    z-index: 2; /* Content should be on top of the background */
    padding: 50px;
    box-sizing: border-box;
    color: white; /* Make text white for readability */
    text-align: left;
}

#dintev-article img {
    width: auto; /* Ensure image fills available width */
    height: auto; /* Maintain aspect ratio */
    max-height: 400px; /* Limit the height to keep images uniform */
    object-fit: cover; /* Ensures image fills container without distortion */
    z-index: 2; /* Ensure image is above the overlay */
}

/* Overlay to improve readability on images */
#dintev-article::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5); /* Optional dark overlay */
    z-index: 1;
}

/* Alternating layouts for text and images */
#dintev-article:nth-child(odd) .content {
    text-align: left; /* Text left for odd articles */
}

#dintev-article:nth-child(odd) img {
    grid-column: 1; /* Image on the left for odd articles */
}

#dintev-article:nth-child(odd) .content {
    grid-column: 2; /* Content on the right for odd articles */
}

/* Even articles (text on the left, image on the right) */
#dintev-article:nth-child(even) .content {
    text-align: right; /* Text right for even articles */
}

#dintev-article:nth-child(even) img {
    grid-column: 2; /* Image on the right for even articles */
}

#dintev-article:nth-child(even) .content {
    grid-column: 1; /* Content on the left for even articles */
}

/* Flexbox center content vertically within article */
#dintev-article .content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%; /* Ensure content takes full height of the article */
}

/* Call to Action button styling */
#dintev-article .cta {
    display: block;
    margin: 10px auto 0;
    padding: 10px 20px;
    background-color: #fff;
    color: #000;
    text-decoration: none;
    border-radius: 5px;
}

/* Responsiveness for small screens */
@media (max-width: 768px) {
    #dintev-article {
        grid-template-columns: 1fr; /* Stack text and image vertically on small screens */
        height: auto; /* Allow articles to resize */
    }

    #dintev-article img {
        width: 100%; /* Ensure images are responsive */
    }

    #dintev-article .content {
        text-align: center;
        padding: 1rem;
    }
}


.dintv2_col-text {
  height: 30em;
}
.dintv2_grid-flex {
  display: flex;
  flex-grow: 1;
  flex-direction: row;
  justify-content: space-around;
}
.dintv2_col {
  flex: 1;
}
.dintv2_col-left {
  order: -1;
}
.dintv2_col-text {
  display: flex;
  align-items: center;
  justify-content: center;
}


.dintv2_title {
  font-size: 2em;
  font-weight: bold;
  text-align: center;
  margin-bottom: 0.5em;
  color: #CB8938;
}


.dintv2_Aligner-item {
  width: 80%;
}
.dintv2_col-image {
  background-size: cover;
  background-position: center center;
}

@media (max-width: 640px) {
  .dintv2_grid-flex {
    height: 40em;
    flex-direction: column;
  }
  .dintv2_col {
    order: 0;
  }
  .dintv2_col-text div p {
    padding: 1em;
  }
  .dintv2_Aligner-item {
    width: 90%;
  }
}
