@import url('https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap');

/* Custom CSS Styles */
:root {
    --hvccc-black: #3e3e40;
    --hvccc-navy: #115e67;
    --hvccc-green: #00b176;
    --hvccc-light-blue: #0098af;
    --hvccc-blue: #004c97;
    --hvccc-dark-blue: #00205b;
    
    /* Custom Gradient */
    --hvccc-gradient: linear-gradient(90deg,         
        var(--hvccc-light-blue) 100%
    );

    /* Full Brand Gradient - Multi-color transition */
    --hvccc-gradient-full: linear-gradient(90deg, 
        var(--hvccc-navy) 0%, 
        var(--hvccc-green) 30%, 
        var(--hvccc-light-blue) 60%, 
        var(--hvccc-blue) 80%, 
        var(--hvccc-dark-blue) 100%
    );    
   
    /* Configurable for mobile */
    --hvccc-gradient-mobile: var(--hvccc-gradient-full);

    /* Font Sizes */
    --fs-title: 10rem;        /* Huge hero titles */
    --fs-h1: 2.5rem;          /* Main headings */
    --fs-h2: 2rem;            /* Section headings */
    --fs-h3: 1.75rem;         /* Subheadings */
    --fs-h4: 1.5rem;          /* Category headings */
    --fs-body: 1rem;          /* Standard text */
    --fs-small: 0.875rem;     /* Small/muted text */
}

/* Tablet Overrides (768px to 991px) */
@media (min-width: 768px) and (max-width: 991.98px) {
    :root {
        --fs-title: 6rem;
        --fs-h1: 2.25rem;
        --fs-h2: 1.75rem;
    }
}

/* Laptop / Large Tablet Overrides (992px to 1399px) */
@media (min-width: 992px) and (max-width: 1399.98px) {
    :root {
        --fs-title: 4.5rem; 
        --fs-h1: 1.5rem;    
        --fs-h2: 1.2rem;    
        --fs-h3: 1.1rem;    
    }

    .hero-section {
        height: 550px !important; /* Set a fixed height instead of vh to ensure image is visible on short viewports */
    }
}

/* Typography Classes */
.team-img-soft {
    filter: blur(0.4px); /* Anti-Moiré soften */
    transform: translateZ(0); /* Force GPU */
    image-rendering: auto; 
}

.text-title {
    font-size: var(--fs-title);
    line-height: 1.2;
    font-weight: 500;
}

.text-heading {
    font-size: var(--fs-h1);
    line-height: 1.3;
}

.text-sub-heading {
    font-size: var(--fs-h3);
    font-weight: 200;
}

.text-body {
    font-size: var(--fs-body);
    line-height: 1.6;
}

.hvccc-text-gradient {
    background: var(--hvccc-gradient-full);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    font-weight: 800;
}

body {
    background-color: #f8f9fa;
    font-family: 'Open Sans', sans-serif;
    padding-top: 80px; 
}

@media (max-width: 991.98px) {
    body {
        padding-top: 80px; /* Consistent with desktop */
    }
    .text-title {
        font-size: 4rem; /* Smaller Welcome title on mobile */
    }
    .hero-section .container {
        margin-top: -1rem !important; /* Move title down on mobile (Desktop is -5rem) */
    }
}

/* Tablet Layout Enhancements */
@media (min-width: 768px) and (max-width: 991.98px) {
    .text-title {
        font-size: var(--fs-title); /* Uses the tablet override defined in :root */
    }
    .hero-section .container {
        margin-top: 1rem !important; /* Changed from -2rem to positive margin to clear navbar in landscape */
    }
    
    /* Reduce vertical section padding for tablets to optimize vertical space */
    section.py-5, .py-5 {
        padding-top: 3rem !important;
        padding-bottom: 3rem !important;
    }

    /* Ensure horizontal padding doesn't collapse too much on tablets */
    .px-lg-5 {
        padding-left: 2rem !important;
        padding-right: 2rem !important;
    }

    
    .col-md-4 {
        flex: 0 0 auto;
        width: 50%; 
    }
}

/* Laptop / Large Tablet Specific Adjustments */
@media (min-width: 992px) and (max-width: 1399.98px) {
    .text-title {
        font-size: var(--fs-title);
    }
    .hero-section .container {
        margin-top: 0rem !important; /* Changed from -3.5rem to 0 to prevent overlap with navbar on shorter viewports */
    }
    section.py-5, .py-5 {
        padding-top: 4rem !important;
        padding-bottom: 4rem !important;
    }
}

.card-custom-border {
    background-color: transparent !important;
    border: none !important;
    border-bottom: 2px solid transparent !important;
    border-image: var(--hvccc-gradient-full) 1 !important;
    box-shadow: none !important;
}

/* Responsive Card to Line Toggle */
.layout-card-mobile {
    background-color: transparent !important;
    box-shadow: none !important;
    border: none !important;
    border-radius: 0 !important;
}

/* Custom Border Helpers */
.border-hvccc-navy { border-color: var(--hvccc-navy) !important; }
.border-hvccc-green { border-color: var(--hvccc-green) !important; }
.border-hvccc-light-blue { border-color: var(--hvccc-light-blue) !important; }

.layout-card-mobile.layout-separator {
    border-bottom: 2px solid transparent !important;
    border-image: var(--hvccc-gradient-full) 1 !important;
}

@media (min-width: 992px) {
    .layout-card-mobile {
        margin-bottom: 4rem !important;
        padding-bottom: 3rem !important;
    }
}

@media (max-width: 991.98px) {
    .layout-card-mobile {
        background-color: #fff !important;
        box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
        border: 1px solid rgba(0, 0, 0, 0.125) !important;
        border-radius: 0.375rem !important;
        margin-bottom: 2rem !important;
    }
}

.quote-gradient-line {
    border: none;
    height: 2px;
    background: var(--hvccc-gradient-full);
    opacity: 1;
    margin: 1.5rem 0;
    width: 100%;
}

.quote-container {
    position: relative;
    padding-left: 3rem;    
}

.quote-container .text-sub-heading {
    font-weight: 350 !important; 
}

/* FAQ Accordion Styling */
.faq-accordion .accordion-item {
    border: none;
    background: transparent;
    margin-bottom: 0;
}

.faq-accordion .accordion-button {
    background: transparent;
    box-shadow: none;
    padding: 1.5rem 1rem 1.5rem 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--hvccc-black);
}

.faq-accordion .accordion-button::after {
    display: none; /* Remove default bootstrap arrow */
}

.faq-accordion .faq-arrow {
    width: 20px;
    height: 20px;
    background: var(--hvccc-gradient-full);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.faq-accordion .faq-arrow svg {
    width: 10px;
    height: 10px;
    fill: white;
    transition: transform 0.3s ease;
}

.faq-accordion .accordion-button:not(.collapsed) .faq-arrow svg {
    transform: rotate(180deg);
}

.faq-accordion .accordion-body {
    padding: 1rem 0 2rem 0;
    font-size: 1.1rem;
    line-height: 1.7;
    color: var(--hvccc-black);
}

.faq-accordion .accordion-item {
    border-bottom: none;
}

.faq-accordion .accordion-button:not(.collapsed) {
    color: var(--hvccc-navy);
    padding-bottom: 0.5rem;
}

/* Custom Hyperlink Styles */
a:not(.btn):not(.nav-link):not(.dropdown-item) {
    color: var(--hvccc-green);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease, border-bottom 0.3s ease;
    border-bottom: 1px solid transparent;
}

a:not(.btn):not(.nav-link):not(.dropdown-item):hover {
    color: var(--hvccc-light-blue);
    border-bottom: 1px solid var(--hvccc-light-blue);
}

/* Navbar specific color overrides */
.navbar-nav .nav-link {
    color: var(--hvccc-black) !important;
}

.dropdown-item {
    color: var(--hvccc-black) !important;
    font-weight: 500;
}

.navbar-nav .nav-link:hover,
.dropdown-item:hover {
    color: var(--hvccc-light-blue) !important;
}

/* Adjust navbar spacing for medium screens to prevent "Member Portal" overflow */
@media (min-width: 992px) and (max-width: 1200px) {
    .navbar-nav .nav-item {
        padding-left: 0.25rem !important;
        padding-right: 0.25rem !important;
    }
    .navbar-nav .nav-link {
        font-size: 0.9rem;
    }
    .btn-primary {
        padding: 0.5rem 1rem !important;
        font-size: 0.9rem;
    }
}

/* Remove blue tap highlight and focus ring on mobile */
.navbar-nav .nav-link,
.dropdown-item,
.navbar-toggler {
    -webkit-tap-highlight-color: transparent;
    outline: none !important;
    box-shadow: none !important;
}

.faq-separator {
    border: none;
    height: 2px;
    background: var(--hvccc-gradient-full);
    opacity: 1;
    margin: 0;
}

.quote-mark {
    position: absolute;
    left: 0;    
    font-size: 5rem;
    font-family: serif;
    line-height: 1;
    background-color: white;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    opacity: 0.5;
}

h1, h2, h3, h4, h5, h6,
.navbar-brand,
.btn {
    font-family: 'Open Sans', sans-serif;
    font-weight: 700;
}

/* Brand color mappings for Bootstrap utility usage */
.bg-primary {
    background-color: var(--hvccc-blue) !important;
}

.bg-secondary {
    background-color: var(--hvccc-navy) !important;
}

.bg-info {
    background-color: var(--hvccc-light-blue) !important;
}

.bg-warning {
    background-color: var(--hvccc-green) !important;
}

.bg-dark {
    background-color: var(--hvccc-black) !important;
}

.text-primary {
    color: var(--hvccc-blue) !important;
}

.text-dark {
    color: var(--hvccc-dark-blue) !important;
}

.profile-image-square {
    width: 100%;
    aspect-ratio: 1/1;
    object-fit: cover;
    object-position: center 25%;
}

.text-spaced {
    letter-spacing: 1px;
}

.brand-slogan {
    font-size: 1.15rem;
    letter-spacing: 0.5px;
}

.value-icon {
    height: 120px;
    width: 100%;
    object-fit: contain;
}

.btn-primary {
    background-color: var(--hvccc-light-blue) !important;
    background-image: none !important;
    border: 2px solid transparent !important;
    background-clip: padding-box;
    -webkit-background-clip: padding-box;
    transition: all 0.3s ease;
    border-radius: 50px; /* Pill shape */
    padding: 0.5rem 2rem; /* Consistent padding */
    font-weight: 600;
    color: #ffffff !important;
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
    background-color: white !important;
    color: var(--hvccc-light-blue) !important;
    border: 2px solid var(--hvccc-light-blue) !important;
    background-image: none !important;
}

/* Inverted Gradient Button for Feature Cards */
.btn-inverted-gradient {
    background: #ffffff;
    color: var(--hvccc-light-blue);
    border: 2px solid var(--hvccc-light-blue);
    background-clip: padding-box;
    -webkit-background-clip: padding-box;
    border-radius: 50px; /* Pill shape */
    padding: 0.5rem 1.5rem;
    position: relative;
    z-index: 1;
    overflow: hidden;
    font-weight: 700;
}

/* Text Gradient within the inverted button */
.btn-inverted-gradient span {
    color: var(--hvccc-light-blue);
    display: inline-block;
}

.btn-inverted-gradient:hover,
.btn-inverted-gradient:focus,
.btn-inverted-gradient:active {
    background-color: var(--hvccc-light-blue) !important;
    background-image: none !important;
    color: #ffffff !important;
    border: 2px solid transparent !important;
}

/* Ensure span text turns white on hover */
.btn-inverted-gradient:hover span {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}

.btn-inverted-gradient:active {
    transform: scale(0.98);
}

/* Navbar improvements */
.navbar-brand {
    font-weight: 700;
}

.navbar .nav-link {
    color: var(--hvccc-black) !important;
}

.navbar .nav-link:hover {
    color: var(--hvccc-light-blue) !important;
}

.dropdown-menu {
    border-radius: 12px;
}

.dropdown-item:hover {
    background-color: #f8f9fa;
    color: var(--hvccc-blue);
}

.navbar .btn-primary {
    transition: transform 0.2s ease;
}

.navbar .btn-primary:active {
    transform: scale(0.95);
}

/* Hero section with Parallax */
.hero-section {
    height: 80vh; 
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4));
    background-repeat: no-repeat !important; /* Prevent tiling at ultra-wide zooms */
    background-size: cover !important;
    margin-top: -56px;
}

/* Mobile Fixes & Reactive Design */
@media (max-width: 991.98px) {
    .index-hero-bg.hero-section {
        min-height: 50vh !important;
        height: auto !important;
        align-items: flex-end !important; /* Keep items at the bottom */
        padding-bottom: 2rem;
        background-color: transparent !important;
    }

    .index-hero-bg.hero-section .container {
        margin-top: 0 !important; /* Remove the pull-up margin to let it sit at the bottom */
        padding-bottom: 0 !important; 
    }

    /* Navbar Mobile Adjustments */
    .navbar .container {
        flex-direction: row;
        flex-wrap: nowrap;
        justify-content: space-between;
    }

    .navbar-brand {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        max-width: 80%;
    }
    
    .navbar-brand img {
        width: 40px !important;
        height: 40px !important;
    }
    
    .navbar-brand .hvccc-text-gradient {
        font-size: 0.85rem !important;
        margin-left: 8px !important;
        white-space: normal;
        line-height: 1.2;
    }

    .navbar-collapse {
        background: #fff;
        padding: 0;
        margin: 0;
        box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        text-align: left;
        /* Position over page content instead of pushing it down */
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        z-index: 1000;
        border-top: 1px solid #f0f0f0;
    }

    .navbar-nav .nav-item {
        width: 100%;
        padding: 0;
    }

    .navbar-nav .nav-item:last-child {
        padding: 20px;
        background: #fff;
        display: flex;
        justify-content: center;
    }

    .navbar-nav .nav-link {
        font-size: 1.15rem;
        letter-spacing: 0.5px;
        padding: 18px 20px !important;
        border-bottom: 1px solid #ddd;
        display: block;
        width: 100%;
        background: #ffffff;
        color: #333 !important;
        text-align: center;
    }

    .dropdown-menu {
        border: none !important;
        box-shadow: none !important;
        text-align: center;
        background: #fafafa;
        margin-top: 0 !important;
        padding: 0;
        border-radius: 0;
    }

    .dropdown-item {
        padding: 16px 20px 16px 40px !important;
        font-size: 1.05rem;
        border-bottom: 1px solid #f0f0f0;
        margin-bottom: 0;
        border-radius: 0;
        white-space: normal;
        background: #fafafa;
        color: #555 !important;
        text-align: center;
    }

    /* Fix for hamburger menu visibility on mobile */
    .navbar-toggler {
        border-color: rgba(0,0,0,0.1) !important;
        padding: 4px 8px;
    }

    .navbar-toggler-icon {
        background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%280, 0, 0, 0.7%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important;
    }


    .dropdown-item:last-child {
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .hero-section h1 {
        font-size: 2.25rem !important; /* Reduced for mobile viewport */
    }

    .hero-section p {
        font-size: 1.1rem !important; /* Slightly smaller for mobile */
    }

    /* Cards & Spacing */
    .card {
        margin-bottom: 2rem;
    }
}

/* Sub-page Hero Styles - Tailwind-to-Bootstrap Migration */
.sub-hero-section {
    position: relative;
    min-height: 75vh;
    display: flex;
    align-items: flex-end;
    color: white;
    overflow: visible !important;
}

/* Background Layer */
.sub-hero-bg {
    position: absolute;
    inset: 0;
    z-index: -10;
    background-color: var(--hvccc-navy);
    background-attachment: fixed !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
    background-size: cover !important;
}

/* Content Box Styling - Removed Dot Texture & Frosted Look */
.sub-hero-content-box {
    width: 100%;
    /* Create a transparent version of the custom gradient using an overlay technique */
    background: linear-gradient(90deg, 
        rgba(17, 94, 103, 0.7) 0%, 
        rgba(0, 177, 118, 0.7) 30%, 
        rgba(0, 152, 175, 0.7) 60%, 
        rgba(0, 76, 151, 0.7) 80%, 
        rgba(0, 32, 91, 0.7) 100%
    );
    padding: 3rem;
    position: relative;
    z-index: 40;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    border-left: 8px solid rgba(255, 255, 255, 0.3); /* White/30 for better contrast on gradient */
    transition: opacity 0.3s ease;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.sub-hero-header {
    font-size: 2.5rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    position: relative;
    z-index: 10;
}

.sub-hero-accent-line {
    width: 80px;
    height: 6px;
    background-color: var(--hvccc-green);
    margin-bottom: 2rem;
    position: relative;
    z-index: 10;
}

.sub-hero-lead {
    font-size: 1.25rem;
    font-weight: 400;
    opacity: 0.95;
    line-height: 1.6;
    max-width: 600px;
    position: relative;
    z-index: 10;
}

@media (min-width: 768px) {
    .sub-hero-content-box {
        width: 45%; /* Slightly less than half the page width */
        padding: 4rem 6rem 4rem 4rem;
        padding-right: 10%;
        transform: translateY(15px); /* Only a few pixels overlap on desktop too */
    }
    .sub-hero-header {
        font-size: 3.5rem;
    }
}

@media (max-width: 991.98px) {
    .sub-hero-bg {
        background-attachment: scroll !important;
    }
    .sub-hero-content-box {
        margin: 0;
        max-width: 100%;
        transform: translateY(15px); /* Consistent small overlap on mobile */
    }
    .sub-hero-section {
        margin-bottom: 40px;
    }
}

main.container, 
section, 
.container,
footer {
    position: relative;
    z-index: 5; /* Lower than the hero box translateY but part of page layout */
}

@media (max-width: 991.98px) {
    .sub-hero-section {
        min-height: 40vh;
        background-attachment: scroll !important;
        align-items: flex-end; /* Lock content to bottom on mobile */
        margin-bottom: 0;
        padding-top: 40px;
        padding-bottom: 0; /* Remove bottom padding to allow box to sit at base */
    }
    .sub-hero-content-box {
        margin: 0; /* Align to left */
        max-width: 100vw;
        bottom: 0;
        transform: translateY(0); /* Remove the vertical offset from desktop/other mobile block */
        border-radius: 0;
        background: linear-gradient(90deg, 
            rgba(17, 94, 103, 0.7) 0%, 
            rgba(0, 177, 118, 0.7) 30%, 
            rgba(0, 152, 175, 0.7) 60%, 
            rgba(0, 76, 151, 0.7) 80%, 
            rgba(0, 32, 91, 0.7) 100%
        ) !important; /* Higher contrast simplified gradient at 0.7 opacity */
        border-left: none !important; /* Removed side accent on mobile */
        border-top: 6px solid rgba(255, 255, 255, 0.3); /* Subtle top accent instead */
        padding: 2rem 1.5rem; /* Tighter padding for mobile */
    }

    .sub-hero-header {
        font-size: 1.75rem !important; /* Reduced from 2.5rem base for mobile */
        letter-spacing: 0.1em; /* Tighter letter spacing for smaller screens */
    }

    .sub-hero-lead {
        display: none !important;
    }
}

.mobile-hero-subtitle {
    display: none;
}

@media (max-width: 991.98px) {
    .mobile-hero-subtitle {
        display: block;
        background: transparent;
        padding: 1.5rem 1.5rem 2rem 1.5rem;
        font-size: 1.05rem;
        font-weight: 400;
        line-height: 1.6;
        color: #666; /* Muted gray for light mode */
        font-style: italic;
        text-align: left;
        border-bottom: 1px solid #eee;
        margin-bottom: 1rem;
    }

    [prefers-color-scheme="dark"] .mobile-hero-subtitle,
    body.dark-mode .mobile-hero-subtitle {
        background: transparent;
        color: #999; /* Muted gray for dark mode */
        border-bottom: 1px solid #333;
    }
}

/* Gradient Background for Video Section and Page Sections */
.bg-hvccc-gradient {
    background: var(--hvccc-gradient-full);
    color: white;
}

.bg-hvccc-gradient h1, 
.bg-hvccc-gradient h2, 
.bg-hvccc-gradient h3,
.bg-hvccc-gradient .text-sub-heading {
    color: #ffffff !important;
}

.bg-hvccc-gradient p, 
.bg-hvccc-gradient .text-body,
.bg-hvccc-gradient .lead {
    color: #e9ecef !important;
}

@media (max-width: 991.98px) {
    .bg-hvccc-gradient {
        background: var(--hvccc-gradient-mobile) !important;
    }
}

/* Updated Timeline Styles - Modern Left-Justified with Arrows */
.timeline-section {
    position: relative;
    padding: 60px 0 0 0; /* Removed extra bottom padding for exact line termination */
    max-width: 1200px; /* Increased from 900px */
    margin: 0 auto;
}

.timeline-section::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    top: 85px; /* Vertical center of the first arrow */
    height: 0; 
    background-color: var(--hvccc-blue);
    z-index: 1;
}

/* Ensure the vertical line connects cleanly through arrows */
.timeline-item::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    top: 25px; /* Starts at center of current arrow */
    bottom: 0px;
    background-color: var(--hvccc-blue);
    z-index: 1;
}

.timeline-item:last-child::before {    
    display: none; /* HARD DISABLE for the last item's line */
}

.timeline-section::before {
    display: none;
}

.timeline-item {
    position: relative;
    margin-bottom: -40px; /* Slight overlap to shorten page */
    z-index: 2;
    display: flex;
    align-items: flex-start;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-arrow {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 40px;
    background: var(--hvccc-gradient-full);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
    color: #fff;
    box-shadow: none;
    top: 5px; /* Vertical center is at 5px + 20px = 25px */
}

/* Horizontal line pointing to the header */
.timeline-item::after {
    content: '';
    position: absolute;
    top: 25px; /* Aligns with the vertical center of the arrow (top 5px + 20px) */
    height: 2px;
    background-color: var(--hvccc-blue);
    z-index: 1;
    left: 50%;
}

.timeline-item::after {
    content: '';
    position: absolute;
    top: 25px; /* Aligns with the vertical center of the arrow */
    height: 2px;
    background-color: var(--hvccc-blue);
    z-index: 1;
    left: 50%;
}

.timeline-item:has(.timeline-content-left)::after {
    width: 25%; /* Connect exactly to the content on the left */
    transform: translateX(calc(-100% - 20px));
}

.timeline-item:has(.timeline-content-right)::after {
    width: 25%; /* Connect exactly to the content on the right */
    transform: translateX(20px);
}

.timeline-arrow svg {
    width: 18px;
    height: 18px;
}

.timeline-content-wrapper {
    width: 44%;
    display: flex;
    align-items: center;
    gap: 30px;
    position: relative;
    z-index: 2;
}

.timeline-content-left {
    margin-right: auto;
    text-align: right; /* Align text toward the center pointer */
}

.timeline-content-right {
    margin-left: auto;
    flex-direction: row-reverse;
}

.timeline-image-circle {
    width: 100px;
    height: 100px;
    min-width: 100px;
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    align-self: flex-start; /* Aligns image with the top of the content (the heading) */
    margin-top: -10px; /* Slight offset to perfectly center with the heading text line */
    object-fit: cover;
}

.timeline-text {
    text-align: left;
    margin-left: -30px; /* Overlap into the image area */
    position: relative;
    z-index: 2;
    background: #f8f9fa; /* Matches standard body background-color */
    padding: 10px 15px; /* Tighter padding for text block */
    border-radius: 8px;
}

.timeline-content-right .timeline-text {
    margin-left: 0;
    margin-right: -30px; /* Overlap for right-aligned items */
}

@media (max-width: 991.98px) {
    .timeline-section::before,
    .timeline-item::before,
    .timeline-arrow,
    .timeline-item::after {
        display: none !important; /* Remove all decorative timeline elements on mobile */
    }
    .timeline-content-wrapper {
        width: 100%;
        margin-left: 0 !important;
        margin-right: 0 !important;
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0;
        padding: 0;
        background: #ffffff;
        border-radius: 12px;
        overflow: hidden;
        box-shadow: 0 4px 15px rgba(0,0,0,0.05);
        border: 1px solid rgba(0,0,0,0.05);
    }
    .timeline-item {
        margin-bottom: 40px;
        display: block;
        padding: 0 15px; /* Side padding from screen edges */
    }
    .timeline-image-circle {
        width: 100%;
        height: 180px;
        min-width: 100%;
        border-radius: 0; /* Flush with card top */
        margin-top: 0;
        object-fit: cover;
    }
    .timeline-text {
        margin-left: 0 !important;
        margin-right: 0 !important;
        padding: 20px 25px !important;
        background: transparent;
    }
}

/* Feature cards */
.card-img-top {
    height: 250px;
    object-fit: cover;
}

/* Quote Section */
.quote-section {
    position: relative;
    overflow: hidden;
}

.quote-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.quote-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    filter: brightness(0.6); 
}

@media (max-width: 991.98px) {
    .quote-section {
        background-attachment: scroll;
    }
}

.quote-section .text-sub-heading {
    font-size: 1.75rem; 
    line-height: 1.4;
    font-weight: 200;
}

@media (max-width: 991.98px) {
    .quote-section .text-sub-heading {
        font-size: 1.15rem !important; 
    }
}

/* Accordion hover */
.accordion-button:not(.collapsed) {
    background-color: rgba(0, 152, 175, 0.12);
    color: var(--hvccc-blue);
}

/* Image styling */
.img-fluid {
    margin-bottom: 20px;
}

/* Footer improvements */

.bg-hvccc-footer {
    background-color: #f7f7f7 !important;
}

.text-white-50 {
    color: rgba(255, 255, 255, 0.5) !important;
    transition: color 0.15s ease-in-out;
}

.text-white-50:hover {
    color: #ffffff !important;
}

.copyright-text {
    color: rgba(255, 255, 255, 0.5) !important;
    font-size: var(--fs-small);
}

footer {
    display: block !important;
}

/* Ensure content pushes footer down */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main, .flex-grow-1 {
    flex-grow: 1;
}


/* Dark Mode Support (Low Contrast / High Readability) */
@media (prefers-color-scheme: dark) {
    :root {
        --hvccc-black: #000000; 
    }

    body {
        background-color: #1a1a1a !important; 
        color: #d1d1d1 !important;
    }

    .bg-light {
        background-color: #252525 !important;
    }

    .bg-hvccc-gradient {
        position: relative;
        overflow: hidden;
    }

    .bg-hvccc-gradient::before {
        content: "";
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.4); 
        pointer-events: none;
    }

    .bg-hvccc-gradient h1, .bg-hvccc-gradient h2, .bg-hvccc-gradient h3, .bg-hvccc-gradient p {
        text-shadow: 0 1px 2px rgba(0,0,0,0.5) !important;
        position: relative;
        z-index: 2;
    }

    .navbar {
        background-color: #2b2b2b !important;
        border-bottom: 1px solid #444 !important;
        box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.5) !important;
    }

    .navbar-brand .me-3,
    footer .mb-2.d-flex.align-items-center.justify-content-center {
        background-color: #ffffff !important;
        border-radius: 0 !important;
        padding: 0 !important;
        width: 60px !important;
        height: 60px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        overflow: hidden !important;
    }
    
    .navbar-brand img, footer .mb-2 img {
        filter: none !important;
        display: block !important;
        margin-bottom: -1px !important;
        width: 60px !important;
        height: 60px !important;
    }

    .navbar-nav .nav-link, .brand-slogan {
        color: #f8f9fa !important;
    }

    .dropdown-menu {
        background-color: #252525 !important;
        border: 1px solid #444 !important;
    }

    .dropdown-item {
        background-color: transparent !important;
        color: #e9ecef !important;
        border-bottom: 1px solid #333 !important;
    }

    .dropdown-item:hover, .dropdown-item:focus {
        background-color: #383838 !important;
        color: #ffffff !important;
    }

    /* Buttons */
    .btn-primary {
        background-color: #007d91 !important;
        background-image: none !important;
        border: 2px solid transparent !important;
        color: #ffffff !important;
        -webkit-text-fill-color: #ffffff !important;
        -webkit-background-clip: padding-box !important;
        background-clip: padding-box !important;
    }
    
    .btn-primary:hover {
        background-color: var(--hvccc-light-blue) !important;
        background-image: none !important;
        color: #000000 !important;
        -webkit-text-fill-color: #000000 !important;
        border: 2px solid var(--hvccc-light-blue) !important;
    }

    .btn-inverted-gradient {
        background-color: #1a1a1a !important;
        background-image: none !important;
        border: 2px solid #444 !important;
        color: #ffffff !important;
        -webkit-text-fill-color: #ffffff !important;
    }

    .btn-inverted-gradient span {
        background: none !important; 
        background-image: none !important;
        color: #ffffff !important;
        -webkit-text-fill-color: #ffffff !important;
        -webkit-background-clip: padding-box !important;
        background-clip: padding-box !important;
    }

    .btn-inverted-gradient:hover {
        background-color: var(--hvccc-light-blue) !important;
        color: #000000 !important;
        -webkit-text-fill-color: #000000 !important;
        border: 2px solid transparent !important;
    }

    .btn-inverted-gradient:hover span {
        color: #000000 !important;
        -webkit-text-fill-color: #000000 !important;
    }

    /* Cards & Accordions */
    .card, .accordion-item, .contact-cta-container, 
    .bg-white, .bg-hvccc-footer, .timeline-text, .history-step-card {
        background-color: #2b2b2b !important;
        color: #d1d1d1 !important;
        border: 1px solid #444 !important;
    }

    @media (max-width: 991.98px) {
        .layout-card-mobile,
        .timeline-content-wrapper {
            background-color: #222222 !important;
            color: #d1d1d1 !important;
            border: 1px solid #333 !important;
        }
    }

    .accordion-button {
        background-color: #2b2b2b !important;
        color: #d1d1d1 !important;
    }

    .accordion-button:not(.collapsed) {
        background-color: #383838 !important;
        color: #d1d1d1 !important;
    }

    .accordion-body, .timeline-text p, .timeline-text li, .timeline-text .text-body, .history-step-card p, .history-step-card li {
        color: #d1d1d1 !important;
    }

    .timeline-text h3, .timeline-text h4, .timeline-text .h5, .history-step-card h3, .history-step-card h4 {
        color: #f8f9fa !important;
    }

    .faq-accordion .faq-arrow {
        background: var(--hvccc-navy) !important;
    }

    .faq-accordion .faq-arrow svg {
        fill: #000000 !important;
    }

    .timeline-item::before {
        background-color: #333 !important;
    }

    .timeline-arrow {
        background: var(--hvccc-light-blue) !important;
        border: 2px solid #1a1a1a !important;
    }

    .timeline-arrow svg {
        fill: #000000 !important;
    }

    .timeline-item::after {
        background-color: #333 !important;
    }

    /* Rainbow Fix: Explicitly override global gradient blocks */
    .hvccc-text-gradient,
    .btn-inverted-gradient span,
    .quote-gradient-line,
    .faq-arrow,
    .sub-hero-accent-line {
        background-image: none !important;
        background: transparent !important;
        background-clip: padding-box !important;
        -webkit-background-clip: padding-box !important;
        -webkit-text-fill-color: initial !important;
    }

    .hvccc-text-gradient,
    .btn-inverted-gradient span {
        color: #ffffff !important;
        -webkit-text-fill-color: #ffffff !important;
    }

    .quote-gradient-line,
    .sub-hero-accent-line {
        background-color: var(--hvccc-navy) !important;
    }

    @media (max-width: 991.98px) {
        .navbar-toggler { border-color: rgba(255, 255, 255, 0.5) !important; }
        .navbar-toggler-icon { background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 1.0%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") !important; }
        .navbar-collapse, .navbar-nav .nav-link, .navbar-nav .nav-item:last-child { background: #2b2b2b !important; color: #fff !important; border-color: rgba(255,255,255,0.1) !important; }
        .dropdown-menu { background: #1a1a1a !important; }
        .dropdown-item { color: #d1d1d1 !important; border-color: rgba(255,255,255,0.05) !important; }
        
        .quote-gradient-line {
            background: var(--hvccc-gradient-full) !important;
        }
    }

    /* Text colors */
    .text-body,
    .text-muted,
    .card-text,
    .text-sub-heading,
    .layout-card-mobile h3,
    .timeline-text h3 {
        color: #adb5bd !important;
    }

    /* Footer Address and Contact */
    footer .text-dark,
    .text-dark[class*="text-dark"] {
        color: var(--hvccc-light-blue) !important;
    }
}







/* Standardizing Video Styles */
.vimeo-video-player {
    width: 100%;
    height: 100%;
    border: none;
}

/* Fullscreen logic targeting the container for better cross-browser results */
.ratio:fullscreen, .ratio:-webkit-full-screen, .ratio:-moz-full-screen, .ratio:-ms-fullscreen {
    width: 100vw !important;
    height: 100vh !important;
    max-width: none !important;
    max-height: none !important;
    background: black !important;
}



