/* Hero Banner Section */
.sector-hero {
    position: relative;
    height: 60vh;
    overflow: hidden;
    width: 100%;
}

/* Hero Background Container and Animation Styles */
.hero-background-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.sector-hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    z-index: 0;
}

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

.sector-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    z-index: 1;
}

.sector-hero-overlay h1 {
    color: white;
    font-size: 5rem;
    font-weight: bold;
    max-width: 80%;
    text-shadow: 
        3px 3px 12px rgba(0, 0, 0, 0.9),
        0 0 20px rgba(0, 0, 0, 0.7),
        2px 2px 6px rgba(0, 0, 0, 1),
        -1px -1px 3px rgba(0, 0, 0, 0.8);
    line-height: 1.2;
    text-align: center;
}

/* Mobile responsive overrides for hero title */
@media (max-width: 768px) {
    .sector-hero-overlay {
        justify-content: center;
        text-align: center;
    }
    
    .sector-hero-overlay h1 {
        font-size: clamp(1.6rem, 4.5vw, 2.2rem) !important; /* Even bigger: 26px-35px */
        max-width: 95% !important;
        line-height: 1.3 !important;
        text-align: center !important;
    }
}

@media (max-width: 576px) {
    .sector-hero-overlay {
        justify-content: center;
        text-align: center;
    }
    
    .sector-hero-overlay h1 {
        font-size: clamp(1.4rem, 5vw, 1.8rem) !important; /* Bigger: 22px-29px */
        max-width: 98% !important;
        line-height: 1.3 !important;
        text-align: center !important;
    }
}

@media (max-width: 480px) {
    .sector-hero-overlay {
        justify-content: center;
        align-items: center;
        text-align: center;
    }
    
    .sector-hero-overlay h1 {
        font-size: clamp(1.2rem, 5.5vw, 1.6rem) !important; /* Bigger: 19px-26px */
        max-width: 100% !important;
        line-height: 1.3 !important; /* Tighter for more space */
        text-align: center !important;
        word-wrap: break-word;
        hyphens: auto;
    }
}

@media (max-width: 360px) {
    .sector-hero-overlay h1 {
        font-size: clamp(1rem, 6vw, 1.3rem) !important; /* Bigger: 16px-21px */
        line-height: 1.4 !important;
        text-align: center !important;
    }
}

/* Title Section */
.sector-title {
    background-color: #194164;
    color: white;
    padding: 2.5rem 0;
    text-align: center;
}

.sector-heading {
    font-size: 4rem;
    font-weight: bold;
    margin-bottom: 1.2rem;
    color: #F8B36A; /* Gold color for the heading */
}

.sector-description {
    max-width: 80%;
    margin: 0 auto;
    font-size: 2rem;
    line-height: 1.6;
    padding: 0 2.5rem;
    text-align: center;
}

/* Mobile responsive overrides for sector title sections */
@media (max-width: 768px) {
    .sector-title {
        padding: 2rem 0; /* Reduce section padding */
    }
    
    .sector-heading {
        font-size: clamp(2rem, 6vw, 2.8rem) !important; /* Much smaller: 32px-45px */
        margin-bottom: 1rem !important;
    }
    
    .sector-description {
        font-size: clamp(1.1rem, 3.5vw, 1.4rem) !important; /* Much smaller: 18px-22px */
        line-height: 1.5 !important;
        padding: 0 1.5rem !important; /* Reduce horizontal padding */
        max-width: 95% !important;
    }
}

@media (max-width: 576px) {
    .sector-title {
        padding: 1.5rem 0; /* Even less section padding */
    }
    
    .sector-heading {
        font-size: clamp(1.6rem, 7vw, 2.2rem) !important; /* Mobile friendly: 26px-35px */
        margin-bottom: 0.8rem !important;
    }
    
    .sector-description {
        font-size: clamp(1rem, 4vw, 1.2rem) !important; /* Mobile friendly: 16px-19px */
        line-height: 1.4 !important;
        padding: 0 1rem !important;
        max-width: 98% !important;
    }
}

@media (max-width: 480px) {
    .sector-title {
        padding: 1.2rem 0; /* Minimal section padding */
    }
    
    .sector-heading {
        font-size: clamp(1.4rem, 8vw, 1.8rem) !important; /* Small mobile: 22px-29px */
        margin-bottom: 0.6rem !important;
    }
    
    .sector-description {
        font-size: clamp(0.9rem, 4.5vw, 1.1rem) !important; /* Small mobile: 14px-18px */
        line-height: 1.3 !important;
        padding: 0 0.8rem !important;
        max-width: 100% !important;
    }
}

@media (max-width: 360px) {
    .sector-heading {
        font-size: clamp(1.2rem, 8.5vw, 1.6rem) !important; /* Ultra small: 19px-26px */
        margin-bottom: 0.5rem !important;
    }
    
    .sector-description {
        font-size: clamp(0.85rem, 5vw, 1rem) !important; /* Ultra small: 14px-16px */
        line-height: 1.25 !important;
        padding: 0 0.5rem !important;
    }
}

/* Illustration Sections - Add contour lines background for all animation/illustration sections */
.illustration-section,
.land-animation-section,
.land-first-section,
.env-first-section,
.env-second-section,
.env-third-section,
.survey-animation-section,
.survey-management-section,
.power-animation-section,
.oilandgas-animation-section,
.renewables-animation-section {
    background-image: url('/static/images/common/contour-lines-bg.webp');
    background-size: cover; /* Responsive coverage without white spaces */
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed; /* Parallax effect maintained */
    position: relative;
}

/* Mobile responsive background adjustments */
@media (max-width: 768px) {
    .illustration-section,
    .land-animation-section,
    .land-first-section,
    .env-first-section,
    .env-second-section,
    .env-third-section,
    .survey-animation-section,
    .survey-management-section,
    .power-animation-section,
    .oilandgas-animation-section,
    .renewables-animation-section {
        background-size: 150%; /* Show more of the pattern on tablets */
        background-position: center center;
        background-attachment: scroll; /* Better mobile compatibility */
    }
}

@media (max-width: 576px) {
    .illustration-section,
    .land-animation-section,
    .land-first-section,
    .env-first-section,
    .env-second-section,
    .env-third-section,
    .survey-animation-section,
    .survey-management-section,
    .power-animation-section,
    .oilandgas-animation-section,
    .renewables-animation-section {
        background-size: 180%; /* Show more of the pattern on mobile */
        background-position: center center;
        background-attachment: scroll; /* Better mobile compatibility */
    }
}

@media (max-width: 480px) {
    .illustration-section,
    .land-animation-section,
    .land-first-section,
    .env-first-section,
    .env-second-section,
    .env-third-section,
    .survey-animation-section,
    .survey-management-section,
    .power-animation-section,
    .oilandgas-animation-section,
    .renewables-animation-section {
        background-size: 200%; /* Show more of the pattern on small mobile */
        background-position: center center;
        background-attachment: scroll; /* Better mobile compatibility */
    }
}

/* Ensure animation images stay above the background */
.illustration-section .illustration-container,
.land-animation-section .illustration-container,
.land-first-section .land-first-container,
.env-first-section .env-first-container,
.env-second-section .env-second-container,
.env-third-section .env-third-container,
.survey-animation-section .illustration-container,
.survey-management-section .survey-management-container,
.power-animation-section .illustration-container,
.oilandgas-animation-section .illustration-container,
.renewables-animation-section .illustration-container {
    position: relative;
    z-index: 2;
}

/* Ensure all animation images maintain proper stacking */
.illustration-image,
.land-animation-image,
.land-first-image,
.env-first-image,
.env-second-image,
.env-third-image,
.survey-animation-image,
.survey-management-image,
.power-animation-image,
.oilandgas-animation-image,
.renewables-animation-image,
.downstream-animation-image {
    position: relative;
    z-index: 3;
}

/* Modern Fade-in Animations - Apply only to the images, not the background sections */
.illustration-image,
.land-animation-image,
.land-first-image,
.env-first-image,
.env-second-image,
.env-third-image,
.survey-animation-image,
.survey-management-image,
.power-animation-image,
.oilandgas-animation-image,
.renewables-animation-image,
.downstream-animation-image,
.gis-animation-image,
.gis-second-image,
.gis-third-image,
.gis-fourth-image {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

/* Animation when images become visible */
.illustration-image.fade-in,
.land-animation-image.fade-in,
.land-first-image.fade-in,
.env-first-image.fade-in,
.env-second-image.fade-in,
.env-third-image.fade-in,
.survey-animation-image.fade-in,
.survey-management-image.fade-in,
.power-animation-image.fade-in,
.oilandgas-animation-image.fade-in,
.renewables-animation-image.fade-in,
.downstream-animation-image.fade-in,
.gis-animation-image.fade-in,
.gis-second-image.fade-in,
.gis-third-image.fade-in,
.gis-fourth-image.fade-in {
    opacity: 1;
    transform: translateY(0);
}