/* ============================================================
   Home / Index - Care Nursing Agency
   Consistent section spacing and layout
   ============================================================ */

:root {
    --royal-blue: #002366;
    --royal-blue-light: #003d99;
    --royal-blue-dark: #001a4d;
    --royal-blue-accent: #4169E1;
    --white: #ffffff;
    --light-blue: #E6F2FF;
    --soft-blue: #B3D9FF;
    --section-padding: 5rem 0;
    --section-padding-lg: 6.25rem 0;
}

/* Wrapper for home page sections - consistent pull-up */
#home-page-sections {
    overflow: hidden;
}

#home-page-sections section {
    position: relative;
    width: 100%;
}

/* Text and paragraphs: royal blue everywhere except hero slider and hero video */
#home-page-sections p,
#home-page-sections .block-text,
#home-page-sections .feature-two__box p,
#home-page-sections .feature-one__box p,
#home-page-sections .service-2-text,
#home-page-sections .service-2-text--rich,
#home-page-sections .service-2-text--rich p,
#home-page-sections .service-2-text--rich li,
#home-page-sections .call-to-action .left-content p {
    color: var(--royal-blue);
}
/* Hero slider & hero video: keep light text (do not apply royal-blue) */
#home-page-sections .main-slider p,
#home-page-sections .main-slider .hero-tagline,
#home-page-sections .main-slider .hero-title,
#home-page-sections .main-slider .hero-desc,
#home-page-sections .hero-video-section p,
#home-page-sections .hero-video-section .hero-tagline,
#home-page-sections .hero-video-section .hero-title,
#home-page-sections .hero-video-section .hero-desc {
    color: #E6F2FF !important;
}
/* How It Works (blue background): left side text stays light */
#home-page-sections .trusted-company .trusted-company__content p,
#home-page-sections .trusted-company .trusted-company__image p,
#home-page-sections .trusted-company .block-text,
#home-page-sections .trusted-company .trusted-company__list-text {
    color: rgba(255, 255, 255, 0.95) !important;
}
/* Numbered white boxes on the right: dark text so it’s visible */
#home-page-sections .trusted-company .trusted-company__box p {
    color: var(--royal-blue) !important;
}

/* Scroll-triggered section reveal: sections animate in when they enter the viewport */
.home-section-reveal {
    opacity: 0;
    transform: translateY(36px);
    transition: opacity 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.home-section-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}
/* Optional stagger for direct children (e.g. feature boxes, service cards) */
.home-section-reveal.is-visible .home-reveal-stagger > * {
    animation: homeRevealStagger 0.6s ease-out forwards;
}
.home-section-reveal .home-reveal-stagger > * {
    opacity: 0;
    transform: translateY(20px);
}
.home-section-reveal .home-reveal-stagger > *:nth-child(1) { animation-delay: 0.05s; }
.home-section-reveal .home-reveal-stagger > *:nth-child(2) { animation-delay: 0.12s; }
.home-section-reveal .home-reveal-stagger > *:nth-child(3) { animation-delay: 0.19s; }
.home-section-reveal .home-reveal-stagger > *:nth-child(4) { animation-delay: 0.26s; }
.home-section-reveal .home-reveal-stagger > *:nth-child(5) { animation-delay: 0.33s; }
.home-section-reveal .home-reveal-stagger > *:nth-child(6) { animation-delay: 0.4s; }
@keyframes homeRevealStagger {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Hero slider: full viewport height so background image shows full screen */
#home-page-sections .main-slider,
#home-page-sections .main-slider .swiper-container,
#home-page-sections .main-slider .swiper,
#home-page-sections .main-slider .swiper-wrapper,
#home-page-sections .main-slider .swiper-slide {
    min-height: 100vh;
    height: 100vh;
}
/* Slide effect: each slide full viewport; wrapper width is set by Swiper so slides sit side-by-side and translate */
#home-page-sections .main-slider .swiper-container {
    overflow: hidden;
}
#home-page-sections .main-slider .swiper-slide {
    position: relative;
    height: 100%;
}
#home-page-sections .main-slider .swiper-slide .image-layer {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    min-height: 100%;
    background-size: cover !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
    background-color: transparent !important;
    opacity: 1 !important;
    z-index: 0;
}
/* Dark overlay so text is readable over any image */
#home-page-sections .main-slider .swiper-slide .hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 35, 102, 0.45);
    z-index: 1;
}
/* Content (text + button) above image and overlay, centered in slide */
#home-page-sections .main-slider .swiper-slide .hero-content-wrap {
    position: relative;
    z-index: 2;
    justify-content: center;
}
/* Hero row: full height, content centered in middle of slide */
#home-page-sections .main-slider .swiper-slide .hero-row-center {
    min-height: 100vh;
    width: 100%;
    justify-content: center;
}
#home-page-sections .main-slider .swiper-slide .hero-content-col {
    max-width: 42rem;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}
/* Button: never squash, centered, comfortable size */
#home-page-sections .main-slider .hero-cta-wrap {
    margin-top: 1.5rem;
    text-align: center;
}
#home-page-sections .main-slider .hero-cta-btn {
    display: inline-block;
    min-width: 12rem;
    padding: 1rem 2.25rem;
    font-size: 1.1rem;
    white-space: nowrap;
    text-align: center;
    text-decoration: none;
}
/* Ensure text and button are visible on active slide (override theme animations) */
#home-page-sections .main-slider .swiper-slide-active .hero-tagline,
#home-page-sections .main-slider .swiper-slide-active .hero-title,
#home-page-sections .main-slider .swiper-slide-active .hero-desc,
#home-page-sections .main-slider .swiper-slide-active .hero-cta-btn {
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
}

/* Row gutters fallback (Bootstrap 4 doesn't have g-4) */
#home-page-sections .row.g-4 > [class*="col-"],
#home-page-sections .row.g-3 > [class*="col-"] {
    margin-bottom: 1.5rem;
}

#home-page-sections .row.g-4 .row.g-3 > [class*="col-"] {
    margin-bottom: 0.75rem;
}

/* Hero: content centered; container full height for centering */
#home-page-sections .main-slider .swiper-slide .hero-content-wrap.container {
    padding-top: 0;
    padding-bottom: 0;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

#home-page-sections .main-slider .hero-tagline {
    color: #E6F2FF;
    font-size: 1.35rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

#home-page-sections .main-slider .hero-title {
    margin-bottom: 1rem;
    line-height: 1.2;
    font-size: clamp(2.25rem, 5vw, 3.5rem);
}

#home-page-sections .main-slider .hero-desc {
    color: #E6F2FF;
    margin-bottom: 1.75rem;
    font-size: 1.25rem;
    line-height: 1.6;
}

@media (min-width: 992px) {
    #home-page-sections .main-slider .swiper-slide .container {
        padding-top: 10rem;
        padding-bottom: 11rem;
    }
}

/* Hero video (single video, no slider) */
#home-page-sections .hero-video-section {
    min-height: 100vh;
    height: 100vh;
    position: relative;
    overflow: hidden;
}
#home-page-sections .hero-video-section .hero-video-wrap {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
}
#home-page-sections .hero-video-section .hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}
#home-page-sections .hero-video-section .hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 35, 102, 0.45);
    z-index: 1;
}
#home-page-sections .hero-video-section .hero-video-mov-fallback {
    font-size: 0.8rem;
    bottom: 0.5rem;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}
#home-page-sections .hero-video-section .hero-content-wrap {
    position: relative;
    z-index: 2;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
#home-page-sections .hero-video-section .hero-row-center {
    justify-content: center;
    width: 100%;
}
#home-page-sections .hero-video-section .hero-content-col {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
}
#home-page-sections .hero-video-section .hero-tagline {
    color: #E6F2FF;
    font-size: 1.35rem;
    font-weight: 600;
}
#home-page-sections .hero-video-section .hero-title {
    color: #fff;
    font-size: clamp(2.25rem, 5vw, 3.5rem);
}
#home-page-sections .hero-video-section .hero-desc,
#home-page-sections .hero-video-section .hero-cta-btn {
    color: #E6F2FF;
}
#home-page-sections .hero-video-section .hero-desc { font-size: 1.25rem; }
#home-page-sections .hero-video-section .hero-cta-btn {
    font-size: 1.1rem;
    padding: 1rem 2.25rem;
}

/* Feature strip under hero - stacked cards, icon on top, readable layout */
.home-hero-features {
    margin-top: 0;
    padding: 3rem 0;
    background: linear-gradient(180deg, var(--white) 0%, var(--light-blue) 8%, var(--white) 100%);
    box-shadow: 0 -4px 24px rgba(0, 35, 102, 0.06);
}

/* Override theme's horizontal layout: stack icon → title → paragraph, full width text */
.home-hero-features .feature-two__box {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 2rem 1.5rem;
    min-height: 100%;
    border-radius: 12px;
    border: 1px solid rgba(0, 35, 102, 0.08);
    background: var(--white);
    box-shadow: 0 4px 20px rgba(0, 35, 102, 0.06);
    transition: box-shadow 0.3s ease, transform 0.3s ease, border-color 0.3s ease;
}

.home-hero-features .feature-two__box:hover {
    box-shadow: 0 8px 28px rgba(0, 35, 102, 0.12);
    transform: translateY(-4px);
    border-color: rgba(0, 35, 102, 0.12);
}

.home-hero-features .feature-two__box::before {
    display: none;
}

/* Icon: larger, in a soft circle, royal blue */
.home-hero-features .feature-two__box > i {
    font-size: 2.5rem;
    width: 4rem;
    height: 4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.25rem;
    margin-left: 0;
    color: var(--royal-blue) !important;
    background: linear-gradient(135deg, var(--light-blue) 0%, var(--soft-blue) 100%);
    border-radius: 50%;
    flex-shrink: 0;
}

/* Title (first line): clear heading */
.home-hero-features .feature-two__box strong {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--royal-blue);
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

/* Paragraph: comfortable read, no max-width */
.home-hero-features .feature-two__box p {
    margin: 0;
    margin-left: 0;
    max-width: none;
    font-size: 0.9375rem;
    font-weight: 400;
    line-height: 1.6;
    color: var(--royal-blue);
}

/* Features section - Our Nursing Services */
#home-page-sections .feature-one {
    padding: var(--section-padding-lg);
    background: linear-gradient(180deg, var(--light-blue) 0%, #f0f7ff 100%);
}

#home-page-sections .feature-one .feature-one__section-image {
    max-height: 320px;
    object-fit: cover;
}
#home-page-sections .feature-one .block-title {
    margin-bottom: 1.5rem;
}

#home-page-sections .feature-one .block-text {
    margin-bottom: 2rem;
    padding-right: 1rem;
}

#home-page-sections .feature-one .feature-one__box {
    padding: 2rem 1.5rem;
    height: 100%;
    border-radius: 12px;
    text-align: center;
}

#home-page-sections .feature-one .feature-one__box i {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
}

/* Services section */
#home-page-sections .service-1-section {
    padding: var(--section-padding-lg);
    background: var(--white);
}

#home-page-sections .service-1-section .section_heading {
    margin-bottom: 3.5rem;
}

#home-page-sections .service-1-section .section_heading_title_big {
    line-height: 1.25;
}

#home-page-sections .service-1-section .service-2-block-wrap {
    border-radius: 12px;
    overflow: hidden;
}

#home-page-sections .service-1-section .service-2-block {
    padding: 2rem 1.75rem;
}

#home-page-sections .service-1-section .service-2-image {
    height: 260px;
    background: linear-gradient(135deg, var(--light-blue) 0%, var(--soft-blue) 100%);
}

#home-page-sections .service-1-section .service-2-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Home Our Services: 2x2 grid on larger screens, each card unique and consistent */
#home-page-sections .service-1-section .home-services-grid {
    display: flex;
    flex-wrap: wrap;
}

#home-page-sections .service-1-section .home-service-card {
    display: flex;
}

@media (min-width: 992px) {
    #home-page-sections .service-1-section .home-services-grid {
        margin-left: -0.75rem;
        margin-right: -0.75rem;
    }
    #home-page-sections .service-1-section .home-service-card {
        flex: 0 0 50%;
        max-width: 50%;
        padding-left: 0.75rem;
        padding-right: 0.75rem;
        margin-bottom: 1.5rem;
    }
}

#home-page-sections .service-1-section .service-2-block-wrap {
    display: flex;
    flex-direction: column;
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 35, 102, 0.08);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

#home-page-sections .service-1-section .service-2-block-wrap:hover {
    box-shadow: 0 8px 24px rgba(0, 35, 102, 0.12);
    transform: translateY(-4px);
}

#home-page-sections .service-1-section .service-2-image {
    flex-shrink: 0;
    height: 280px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--light-blue) 0%, var(--soft-blue) 100%);
}

#home-page-sections .service-1-section .service-2-image img,
#home-page-sections .service-1-section .service-2-image .service-2-media {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

#home-page-sections .service-1-section .service-2-block {
    flex: 1 1 auto;
    padding: 1.75rem 1.5rem;
    display: flex;
    flex-direction: column;
}

#home-page-sections .service-1-section .service-2-title {
    color: var(--royal-blue) !important;
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

#home-page-sections .service-1-section .service-2-text {
    color: var(--royal-blue) !important;
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 0;
}

/* Rich Bootstrap content in service descriptions */
#home-page-sections .service-1-section .service-2-text--rich {
    color: var(--royal-blue);
    font-size: 1rem;
    line-height: 1.7;
}
#home-page-sections .service-1-section .service-2-text--rich p {
    margin-bottom: 0.75rem;
    color: var(--royal-blue);
}
#home-page-sections .service-1-section .service-2-text--rich p:last-child {
    margin-bottom: 0;
}
#home-page-sections .service-1-section .service-2-text--rich ul,
#home-page-sections .service-1-section .service-2-text--rich ol {
    margin-bottom: 0.75rem;
    padding-left: 1.25rem;
}
#home-page-sections .service-1-section .service-2-text--rich li {
    margin-bottom: 0.25rem;
}
#home-page-sections .service-1-section .service-2-text--rich a {
    color: var(--royal-blue);
    text-decoration: underline;
}
#home-page-sections .service-1-section .service-2-text--rich a:hover {
    color: var(--royal-blue);
    text-decoration: none;
}
#home-page-sections .service-1-section .service-2-text--rich strong {
    font-weight: 700;
}
#home-page-sections .service-1-section .service-2-text--rich .btn {
    margin-top: 0.5rem;
    margin-right: 0.5rem;
}

/* How It Works */
#home-page-sections .trusted-company,
#home-page-sections .how-it-works-section {
    padding: var(--section-padding-lg);
    background: linear-gradient(135deg, var(--royal-blue) 0%, var(--royal-blue-light) 100%);
}

/* Dedicated section header so "How it works" is clearly the section title */
#home-page-sections .how-it-works-header {
    text-align: center;
    margin-bottom: 3rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.25);
}
#home-page-sections .how-it-works-header__title {
    color: #ffffff !important;
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
    line-height: 1.2;
    letter-spacing: 0.02em;
}
#home-page-sections .how-it-works-header__subtitle {
    color: rgba(255, 255, 255, 0.9) !important;
    font-size: 1.125rem;
    margin: 0;
    max-width: 640px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
}
@media (max-width: 768px) {
    #home-page-sections .how-it-works-header {
        margin-bottom: 2rem;
        padding-bottom: 1.5rem;
    }
    #home-page-sections .how-it-works-header__title {
        font-size: 1.75rem;
    }
    #home-page-sections .how-it-works-header__subtitle {
        font-size: 1rem;
    }
}

#home-page-sections .trusted-company .trusted-company__bg {
    opacity: 0.06;
    background-image: none;
    background-color: var(--white);
}

#home-page-sections .trusted-company .trusted-company__content {
    padding-right: 1rem;
}

#home-page-sections .trusted-company .trusted-company__image > img {
    display: none;
}

#home-page-sections .trusted-company .trusted-company__image p {
    margin-left: 0;
    margin-top: 0;
}

#home-page-sections .trusted-company .trusted-company__box-wrap {
    margin-top: 0;
}

@media (max-width: 991px) {
    #home-page-sections .trusted-company .trusted-company__box-wrap {
        margin-top: 2.5rem;
    }
}

#home-page-sections .trusted-company .trusted-company__box-wrap::before {
    background-color: rgba(255, 255, 255, 0.12);
}

#home-page-sections .trusted-company .trusted-company__box {
    border-left: 4px solid var(--royal-blue-accent);
}

/* Call to Action */
#home-page-sections .call-to-action,
#home-page-sections .cta-section {
    padding: 4rem 0;
}

/* Dedicated CTA header so the section title is clear */
#home-page-sections .cta-header {
    text-align: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.25);
}
#home-page-sections .cta-header__title {
    color: #ffffff !important;
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 0.5rem 0;
    line-height: 1.2;
}
#home-page-sections .cta-header__subtitle {
    color: rgba(255, 255, 255, 0.9) !important;
    font-size: 1.0625rem;
    margin: 0;
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
}

#home-page-sections .call-to-action .left-content h3,
#home-page-sections .cta-section .left-content h3 {
    margin-bottom: 0.5rem;
    color: #ffffff !important;
}

#home-page-sections .call-to-action .left-content p,
#home-page-sections .cta-section .left-content p,
#home-page-sections .cta-section .cta-lead {
    margin-bottom: 0.5rem;
    color: rgba(255, 255, 255, 0.95) !important;
}

#home-page-sections .call-to-action .right-content .thm-btn,
#home-page-sections .cta-section .right-content .thm-btn,
#home-page-sections .cta-section .cta-btn {
    padding: 1rem 2rem;
    font-size: 1.0625rem;
    border-radius: 8px;
    min-width: 12rem;
    text-align: center;
    display: inline-block;
}
/* CTA button full-width on mobile for nicer display */
#home-page-sections .cta-section .cta-button-wrap {
    width: 100%;
}
#home-page-sections .cta-section .cta-button-wrap .cta-btn {
    width: 100%;
    max-width: 20rem;
    margin-left: auto;
    margin-right: auto;
}
@media (max-width: 991px) {
    #home-page-sections .cta-section .cta-button-wrap {
        margin-top: 0.5rem;
    }
    #home-page-sections .cta-section .cta-button-wrap .cta-btn {
        width: 100%;
        max-width: 100%;
        display: block;
    }
}

#home-page-sections .call-to-action .left-content p.mb-0,
#home-page-sections .cta-section .cta-body-html {
    font-weight: 400;
}
#home-page-sections .cta-section .cta-body-html {
    color: rgba(255, 255, 255, 0.95);
}
#home-page-sections .cta-section .cta-body-html p:last-child {
    margin-bottom: 0;
}

@media (max-width: 991px) {
    #home-page-sections .call-to-action,
    #home-page-sections .cta-section {
        padding: 3rem 1rem;
    }
    #home-page-sections .cta-header__title {
        font-size: 1.5rem;
    }
    #home-page-sections .call-to-action .left-content h3,
    #home-page-sections .cta-section .left-content h3 {
        font-size: 1.75rem;
    }
    #home-page-sections .cta-section .cta-body .right-content {
        margin-top: 1rem;
    }
}

/* Responsive section padding */
@media (max-width: 991px) {
    #home-page-sections .feature-one,
    #home-page-sections .service-1-section,
    #home-page-sections .trusted-company {
        padding: 3.5rem 0;
    }
}

@media (max-width: 768px) {
    #home-page-sections .main-slider .swiper-slide .container {
        padding-top: 6rem;
        padding-bottom: 7rem;
    }

    .home-hero-features {
        padding: 2rem 0;
    }

    #section-cta .left-content h3 {
        font-size: 1.5rem;
    }

    /* Hero video & slider: responsive on mobile */
    #home-page-sections .hero-video-section,
    #home-page-sections .main-slider,
    #home-page-sections .main-slider .swiper-container,
    #home-page-sections .main-slider .swiper,
    #home-page-sections .main-slider .swiper-wrapper,
    #home-page-sections .main-slider .swiper-slide {
        min-height: 70vh;
        height: 70vh;
    }
    #home-page-sections .hero-video-section .hero-content-wrap {
        min-height: 70vh;
    }
    #home-page-sections .main-slider .swiper-slide .hero-row-center {
        min-height: 70vh;
    }
    #home-page-sections .hero-video-section .hero-tagline,
    #home-page-sections .main-slider .hero-tagline {
        font-size: 1rem;
    }
    #home-page-sections .hero-video-section .hero-title,
    #home-page-sections .main-slider .hero-title {
        font-size: clamp(1.5rem, 6vw, 2.25rem);
    }
    #home-page-sections .hero-video-section .hero-desc,
    #home-page-sections .main-slider .hero-desc {
        font-size: 0.95rem;
    }
    #home-page-sections .hero-video-section .hero-cta-btn,
    #home-page-sections .main-slider .hero-cta-btn {
        font-size: 0.95rem;
        padding: 0.75rem 1.5rem;
    }
}

@media (max-width: 575px) {
    #home-page-sections .hero-video-section,
    #home-page-sections .main-slider,
    #home-page-sections .main-slider .swiper-container,
    #home-page-sections .main-slider .swiper,
    #home-page-sections .main-slider .swiper-wrapper,
    #home-page-sections .main-slider .swiper-slide {
        min-height: 60vh;
        height: 60vh;
    }
    #home-page-sections .hero-video-section .hero-content-wrap {
        min-height: 60vh;
    }
    #home-page-sections .main-slider .swiper-slide .hero-row-center {
        min-height: 60vh;
    }
    #home-page-sections .hero-video-section .hero-content-wrap .container,
    #home-page-sections .main-slider .swiper-slide .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

