/* Custom Premium Styles - Strict Blue, White, Black Theme */
:root {
    --primary-color: #0056b3; /* Main Blue */
    --primary-dark: #003366;  /* Dark Blue for hover states */
    --dark-bg: #000000;       /* Solid Black for dark sections */
    --light-bg: #f4f7f9;      /* Off-white for section separation */
    --card-bg: #ffffff;       /* Pure White for cards */
    --text-main: #111111;     /* Near Black for main text readability */
    --text-muted: #333333;    /* Very dark gray for readability */
}

/* Global Color Enforcements to Wipe Out Red */
a, a:visited { color: var(--primary-color); }
a:hover, a:focus { color: var(--primary-dark); }

.btn,
.btn--primary,
button,
input[type="submit"],
.s-header__menu-toggle.is-clicked span {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    color: #ffffff !important;
}

.btn:hover,
.btn--primary:hover,
button:hover {
    background-color: var(--primary-dark) !important;
    border-color: var(--primary-dark) !important;
}

/* Header Overrides - Force White */
.s-header__logo a,
.s-header__nav a {
    color: #ffffff !important;
}
.s-header__nav a:hover,
.s-header__nav a:focus {
    color: #cccccc !important;
}
.s-header.sticky .s-header__nav a,
.s-header.sticky .s-header__logo a {
    color: #ffffff !important;
}

/* Overflow Guard: prevent horizontal scroll without breaking window scroll / AOS */
body {
    overflow-x: hidden;
}

/* Ensure Preloader Never Blocks Content */
#preloader,
#loader {
    display: none !important;
    visibility: hidden !important;
}

/* Guarantee Hero Content and sections are always visible */
html.ss-preload .s-hero__content,
.s-hero__content {
    opacity: 1 !important;
    visibility: visible !important;
}

/* Background Video Styles */
.s-hero {
    background-color: #000000 !important;
    position: relative;
    overflow: hidden;
}

.s-hero__bg {
    background-image: none !important; /* Force remove the old background image */
    background-color: #000000 !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 0 !important;
    overflow: hidden !important;
}

.hero-video-bg {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 0 !important;
    object-fit: cover !important;
    opacity: 0.45 !important; /* Stronger contrast for white text */
    pointer-events: none !important;
}

/* Remove any legacy play video button across all screens */
.s-hero__video {
    display: none !important;
}

/* Scroll Down Link */
.s-hero__scroll-link {
    color: #ffffff !important;
}
.s-hero__scroll-link::before {
    background-color: #ffffff !important;
}

/* Hero Content - Desktop Layout: Squarely in the middle, fully visible */
@media screen and (min-width: 992px) {
    .s-hero {
        height: 100vh !important;
        min-height: 600px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: flex-start !important;
        position: relative !important;
    }

    .s-hero__content {
        margin-top: 0 !important;
        height: auto !important;
        padding-top: 6rem !important;
        padding-bottom: 0 !important;
        position: relative !important;
        z-index: 10 !important;
        width: 100% !important;
        opacity: 1 !important;
        visibility: visible !important;
    }

    .s-hero__content .column {
        width: 100% !important;
        max-width: 1100px !important;
    }

    .s-hero__content h1 {
        font-size: clamp(5.5rem, 7.5vw, 10rem) !important;
        line-height: 1.05 !important;
        letter-spacing: -0.03em !important;
        transform: none !important;
        color: #ffffff !important;
        margin-bottom: 2rem !important;
    }

    .s-hero__content h1 span {
        color: #ffffff !important;
    }

    .s-hero__content-about {
        font-size: clamp(2rem, 2.2vw, 2.8rem) !important;
        line-height: 1.5 !important;
        color: rgba(255, 255, 255, 0.92) !important;
        max-width: 850px !important;
    }

    .s-hero__content-about p {
        color: rgba(255, 255, 255, 0.92) !important;
        font-size: inherit !important;
        line-height: inherit !important;
        margin: 0 !important;
    }
}

/* Hero Content - Mobile & Tablet Responsive Layout */
@media screen and (max-width: 991px) {
    .s-hero {
        height: 100vh !important;
        min-height: 520px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: flex-start !important;
        position: relative !important;
        padding: 0 !important;
    }

    .s-hero__content {
        margin-top: 0 !important;
        height: auto !important;
        padding-top: 8rem !important;
        padding-bottom: 4rem !important;
        padding-left: 2.5rem !important;
        padding-right: 2.5rem !important;
        width: 100% !important;
        max-width: 100% !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: flex-start !important;
        position: relative !important;
        z-index: 10 !important;
        opacity: 1 !important;
        visibility: visible !important;
    }

    .s-hero__content .column {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
        flex: 1 1 100% !important;
    }

    .s-hero__content h1 {
        font-size: clamp(3rem, 8.5vw, 4.4rem) !important;
        line-height: 1.15 !important;
        letter-spacing: -0.02em !important;
        transform: none !important;
        color: #ffffff !important;
        margin-top: 0 !important;
        margin-bottom: 1.4rem !important;
        text-align: left !important;
        word-break: normal !important;
        overflow-wrap: break-word !important;
    }

    .s-hero__content h1 span {
        font-size: 1em !important;
        color: #ffffff !important;
        display: inline !important;
    }

    .s-hero__content h1::before {
        display: none !important; /* Prevent dot pattern clutter on mobile */
    }

    .s-hero__content-about {
        font-size: clamp(1.4rem, 3.8vw, 1.8rem) !important;
        line-height: 1.5 !important;
        color: rgba(255, 255, 255, 0.9) !important;
        padding: 0 !important;
        max-width: 100% !important;
    }

    .s-hero__content-about::before {
        display: none !important;
    }

    .s-hero__content-about p {
        font-size: inherit !important;
        line-height: inherit !important;
        color: rgba(255, 255, 255, 0.9) !important;
        margin: 0 !important;
    }

    .s-hero__scroll {
        display: none !important;
    }
}

@media screen and (max-width: 500px) {
    .s-hero__content {
        padding-left: 2rem !important;
        padding-right: 2rem !important;
        padding-top: 7rem !important;
    }

    .s-hero__content h1 {
        font-size: clamp(2.6rem, 8vw, 3.6rem) !important;
        line-height: 1.15 !important;
    }

    .s-hero__content-about {
        font-size: 1.4rem !important;
    }
}

/* Services Section */
.s-services {
    background-color: var(--light-bg);
    padding-top: 12rem;
    padding-bottom: 12rem;
}

.s-services .section-title h3 {
    color: var(--primary-color) !important;
}

.s-services .display-1 {
    color: var(--text-main) !important;
}

.s-services .lead {
    color: var(--text-muted) !important;
}

.services-grid {
    margin-top: 6rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
}

.services-card {
    flex: 1 1 calc(33.333% - 30px);
    min-width: 300px;
    max-width: 400px;
}

.services-card__inner {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 40px 30px;
    height: 100%;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
    z-index: 1;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08); 
}

.services-card__inner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    z-index: -1;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.services-card__inner:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 86, 179, 0.2); 
    border-color: transparent;
}

.services-card__inner:hover::before {
    opacity: 1;
}

.services-card__icon {
    font-size: 4rem;
    color: var(--primary-color);
    margin-bottom: 25px;
    transition: color 0.4s ease, transform 0.4s ease;
}

.services-card__inner:hover .services-card__icon {
    color: #ffffff;
    transform: scale(1.1);
}

.services-card__title {
    color: var(--text-main);
    font-size: 2.2rem;
    margin-bottom: 15px;
    transition: color 0.4s ease;
}

.services-card__text {
    color: var(--text-muted);
    font-size: 1.6rem;
    line-height: 1.7;
    margin-bottom: 0;
    transition: color 0.4s ease;
}

.services-card__inner:hover .services-card__title,
.services-card__inner:hover .services-card__text {
    color: #ffffff;
}

/* Light theme About section */
.s-about {
    background-color: #ffffff !important;
}

.s-about .display-1 {
    color: var(--text-main) !important;
}

.s-about .lead, .s-about p {
    color: var(--text-muted) !important;
}

.s-about .section-title h3 {
    color: var(--primary-color) !important;
}

.item-process {
    padding: 30px;
    background: #ffffff;
    border-radius: 12px;
    margin-bottom: 30px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid rgba(0,0,0,0.05);
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.item-process:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.item-process .item-title {
    color: var(--primary-dark) !important;
}

/* Portfolio Section Overrides */
.s-portfolio {
    background-color: #f4f7f9 !important;
}
.s-portfolio .display-1, .s-portfolio h1 {
    color: var(--text-main) !important;
}
.s-portfolio p {
    color: var(--text-muted) !important;
}
.folio-item__title {
    color: var(--primary-dark) !important;
}

/* Make headers pop globally */
.section-title h3 {
    letter-spacing: 2px;
    color: var(--primary-color) !important;
}

/* Force all red numbered circles/badges to Blue */
.item-process::before,
.item-title::before,
.item-list .item::before,
.s-about__process .column::before {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

/* Force section title numbers (like 01, 02) to Blue */
.section-title::before {
    color: var(--primary-color) !important;
}

/* Contact / CTA Section Overrides */
.s-contact {
    background-color: var(--card-bg) !important; /* Forces White background, removing any red */
}
.s-contact .display-1 {
    color: var(--text-main) !important; /* Forces main text to Black */
}
.s-contact h3,
.s-contact h3.h6 {
    color: var(--primary-color) !important; /* Highlights "Get In Touch" in Blue */
}

/* Footer Overrides */
.s-footer {
    background-color: var(--primary-dark) !important; /* Completely removes the default red background */
}

/* Mobile Section & Card Responsiveness */
@media screen and (max-width: 768px) {
    .services-card {
        flex: 1 1 100% !important;
        min-width: 100% !important;
        max-width: 100% !important;
    }
    .s-services {
        padding-top: 8rem !important;
        padding-bottom: 8rem !important;
    }
    .services-grid {
        margin-top: 4rem !important;
        gap: 20px !important;
    }
}
