.hero-background-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* Video and Image Styling for Hero Background */
.sector-hero-image,
.sector-hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.8s ease-in-out;
    z-index: 0;
}

.sector-hero-image.active,
.sector-hero-video.active {
    opacity: 1;
    z-index: 0;
}

/* Ensure text overlay stays above videos */
.sector-hero-overlay {
    z-index: 2 !important;
}

/* =================== NAMED VIDEO POSITIONING CLASSES =================== */

/* Land Page Videos - Individual positioning by name */
.sector-hero-video.video-real-estate-aerial,
.sector-hero-image.image-real-estate-aerial {
  object-position: center 40%; /* Real estate aerial - shows more top content */
}

.sector-hero-video.video-tower-zoom-in,
.sector-hero-image.image-tower-zoom-in {
  object-position: center 25%; /* Tower zoom in - slight vertical offset */
}

.sector-hero-video.video-oil-field-drone-shot,
.sector-hero-image.image-oil-field-drone-shot {
  object-position: 45% center; /* Oil field drone shot - slight horizontal offset */
}

/* =================== RESPONSIVE ADJUSTMENTS FOR LAND PAGE =================== */

/* Tablet adjustments */
@media (max-width: 768px) {
  .sector-hero-video[class*="video-"],
  .sector-hero-image[class*="image-"] {
    object-position: center 45% !important;
  }
}

/* Mobile adjustments */
@media (max-width: 480px) {
  .sector-hero-video[class*="video-"],
  .sector-hero-image[class*="image-"] {
    object-position: center 50% !important;
  }
}

/* Legacy nth-child positioning - kept for fallback */
.hero-background-container img:nth-child(1),
.hero-background-container video:nth-child(1) { 
    object-position: center 40%; /* First media (real-estate-aerial/desert land) - shows more top content */
}

.hero-background-container img:nth-child(2),
.hero-background-container video:nth-child(2),
.hero-background-container img:nth-child(3),
.hero-background-container video:nth-child(3) { 
    object-position: center 25%; /* Second/Third media (drone-truck-shot/land man) - slight vertical offset */
}

.hero-background-container img:nth-child(4),
.hero-background-container video:nth-child(4),
.hero-background-container img:nth-child(5),
.hero-background-container video:nth-child(5) { 
    object-position: 45% center; /* Fourth/Fifth media (oil-field-drone-shot/oil-well-drone-shot) - slight horizontal offset */
}

.hero-background-container img:nth-child(6),
.hero-background-container video:nth-child(6) { 
    object-position: 45% center; /* Sixth media - slight horizontal offset */
}

/* Land Overview Section */
.land-overview {
    padding: 6rem 0;
    background-color: #f8f9fa;
}

.land-content {
    padding-right: 2rem;
}

.land-heading {
    color: #f39c12;
    font-size: 4rem;
    font-weight: bold;
    margin-bottom: 2rem;
    text-align: center;
}

.land-description {
    font-size: 1.2rem;
    line-height: 1.6;
    color: #333;
    text-align: center;
}

.land-illustration {
    text-align: center;
}

.illustration-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

/* Services Sections */
.services-section {
    padding: 4rem 0;
}

/* Ensure equal height columns */
.services-section .row {
    align-items: stretch;  /* Make columns equal height */
}

.services-section .col-lg-5,
.services-section .col-lg-7 {
    display: flex;  /* Make columns flexbox containers */
    flex-direction: column;
}

.services-blue {
    background-color: #194164;
    color: white;
}

.service-category {
    padding: 2rem;
    position: relative;
}

/* Stacked layout styling for images */
.images-stack {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 5.5rem;
    padding: 2rem 6rem 2rem 4rem;
}

.image-item {
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-image-stacked {
    width: 380px;
    height: 380px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    opacity: 0.95;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Specific positioning for environmental services plant image */
.service-image-stacked[src*="land-feature-6.png"] {
    object-position: 20% center; /* Move image further to the left to show more of the left side */
}

.service-image-stacked:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

/* Responsive adjustments for image stacks */
@media (max-width: 992px) {
    .images-stack {
        gap: 3rem;
        padding: 2rem;
    }
    
    .service-image-stacked {
        width: 320px;
        height: 320px;
    }
}

@media (max-width: 768px) {
    .images-stack {
        flex-direction: row;
        gap: 2rem;
        padding: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .service-image-stacked {
        width: 250px;
        height: 250px;
    }
}

/* Legacy icon stack styling - kept for backwards compatibility */
.icons-stack {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 15rem;
    padding: 2rem 6rem 2rem 4rem;
}

.icon-item {
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-icon-stacked {
    font-size: 8rem;
    color: white;
    opacity: 0.9;
}

.content-stack {
    display: flex;
    flex-direction: column;
    justify-content: space-evenly;  /* Distribute content evenly vertically */
    height: 100%;  /* Take full height to match image stack */
    gap: 2rem;  /* Reduced gap for better distribution */
    padding: 2rem 2rem 2rem 8rem;
}

.content-stack .service-category {
    padding: 0;
}

.service-number {
    color: #f39c12;
    font-size: 1.8rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
    line-height: 1.3;
}

.service-list {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.service-list li {
    font-size: 1.2rem;
    line-height: 1.5;
    margin-bottom: 0.8rem;
    padding-left: 1.2rem;
    position: relative;
}

.service-list li::before {
    content: "●";
    color: #f39c12;
    position: absolute;
    left: 0;
    top: 0;
}

.service-icon-container {
    display: flex;
    justify-content: center;
    margin: 2rem 0;
}

.service-icon {
    font-size: 5.5rem;
    color: white;
    opacity: 0.8;
}

/* Illustration Sections */
.illustration-section {
    padding: 4rem 0;
    background-color: #f8f9fa;
}

.illustration-container {
    text-align: center;
}

.illustration-container .illustration-image {
    max-width: 600px;
    width: 100%;
    height: auto;
}

/* Land Animation Section Specific Styles */
.land-animation-section {
    background-color: #FFFFFF !important;
}

.land-animation-image {
    max-width: 800px !important;
}

/* Land First Section - Individual Classes for Size Control */
.land-first-section {
    background-color: #FFFFFF;
    padding: 6rem 0;
}

.land-first-container {
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
}

.land-first-image {
    max-width: 800px;
    width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}

/* Responsive Adjustments */
@media (max-width: 992px) {
    .land-content {
        padding-right: 0;
        margin-bottom: 3rem;
    }
    
    .service-category {
        padding: 1.5rem;
    }
    
    .icons-stack {
        flex-direction: row;
        gap: 4.5rem;
        padding: 1.5rem 4rem 1.5rem 3rem;
        justify-content: center;
    }
    
    .service-icon-stacked {
        font-size: 6.5rem;
    }
    
    .content-stack {
        gap: 2rem;  /* Consistent reduced spacing */
        padding: 1.5rem 1rem 1.5rem 6rem;
        justify-content: space-evenly;  /* Maintain even distribution */
    }
    
    .service-number {
        font-size: 1.6rem;
    }
    
    .service-list li {
        font-size: 1.1rem;
    }
    
    .illustration-container .illustration-image {
        max-width: 500px;
    }
    
    .land-animation-image {
        max-width: 650px !important;
    }
}

@media (max-width: 768px) {
    .sector-hero {
        height: 45vh;
    }
    
    .sector-hero-overlay h1 {
        font-size: 1.9rem;
        max-width: 95%;
        line-height: 1.1;
        padding-left: 5%;
    }
    
    .sector-heading {
        font-size: 2rem;
    }
    
    .land-overview {
        padding: 4rem 0;
    }
    
    .land-heading {
        font-size: 3rem;
    }
    
    .land-description {
        font-size: 1.1rem;
    }
    
    .services-section {
        padding: 3rem 0;
    }
    
    .service-category {
        padding: 1.5rem 1rem;
        margin-bottom: 2rem;
    }
    
    /* Adjust stacked layout for mobile */
    .icons-stack {
        flex-direction: row;
        gap: 3.5rem;
        padding: 1rem 3rem 1rem 2rem;
        justify-content: center;
    }
    
    .service-icon-stacked {
        font-size: 5.5rem;
    }
    
    .content-stack {
        gap: 1.5rem;  /* Consistent reduced spacing */
        padding: 1rem 1rem 1rem 5rem;
        justify-content: space-evenly;  /* Maintain even distribution */
    }
    
    .service-number {
        font-size: 1.4rem;
    }
    

    
    .service-icon {
        font-size: 4rem;
    }
    
    .illustration-section {
        padding: 3rem 0;
    }
    
    .illustration-container .illustration-image {
        max-width: 400px;
    }
    
    .land-animation-image {
        max-width: 500px !important;
    }
}

@media (max-width: 576px) {
    .sector-hero-overlay h1 {
        font-size: 1.6rem;
        max-width: 98%;
        line-height: 1.0;
        padding-left: 3%;
    }
}

/* Extra small screens (iPhone SE, etc.) */
@media (max-width: 480px) {
    .sector-hero-overlay h1 {
        font-size: 1.4rem;
        max-width: 98%;
        line-height: 1.0;
        padding-left: 2%;
    }
    
    .land-heading {
        font-size: 2.5rem;
    }
    
    .land-description {
        font-size: 1rem;
    }
    
    .service-category {
        padding: 1rem;
    }
    
    /* Further adjust stacked layout for very small screens */
    .icons-stack {
        flex-direction: row;
        gap: 3rem;
        padding: 1rem 1rem;
        justify-content: center;
    }
    
    .service-icon-stacked {
        font-size: 4rem;
    }
    
    .content-stack {
        gap: 1rem;  /* Consistent reduced spacing for mobile */
        padding: 1rem 1rem 1rem 3rem;
        justify-content: space-evenly;  /* Maintain even distribution */
    }
    
    .service-number {
        font-size: 1.2rem;
    }
    
    .service-list li {
        font-size: 1rem;
    }
    
    .service-icon {
        font-size: 3.5rem;
    }
    
    .illustration-container .illustration-image {
        max-width: 300px;
    }
    
    .land-animation-image {
        max-width: 350px !important;
    }
    
    /* Stack the last section's 3 columns vertically on mobile */
    .services-section:last-of-type .col-lg-4 {
        margin-bottom: 2rem;
    }
}

/* Responsive adjustments for land first section */
@media (max-width: 992px) {
    .land-first-image {
        max-width: 650px;
    }
}

@media (max-width: 768px) {
    .land-first-section {
        padding: 3rem 0;
    }
    
    .land-first-image {
        max-width: 500px;
    }
}

@media (max-width: 576px) {
    .land-first-image {
        max-width: 350px;
    }
}

