
/* ==============================================
   FITROAI BODY SCAN — PEARL LIGHT / NAVY SCANNER
============================================== */

.fitro-body-scan {
    --scan-accent: #4268A5;
    --scan-ice: #A9DDFC;
    --scan-muted: #64748B;
    position: relative;
    isolation: isolate;
    width: 100%;
    min-height: 92svh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: #F5F7FB;
    background-image: linear-gradient(115deg, #FAFBFE 0%, #F1F5FA 58%, #E9F0F9 100%);
    color: #17263E;
    padding: 100px 6% 0;
    font-family: inherit;
}

.fitro-body-scan *,
.fitro-body-scan *::before,
.fitro-body-scan *::after {
    box-sizing: border-box;
}

.fitro-scan-ambient {
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
        radial-gradient(
            ellipse at 75% 48%,
            rgba(112, 145, 198, .12),
            transparent 45%
        ),
        radial-gradient(
            ellipse at 10% 90%,
            rgba(160, 184, 218, .14),
            transparent 48%
        );
}

.fitro-scan-container {
    width: 100%;
    max-width: 1320px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: center;
    gap: clamp(35px, 6vw, 100px);
}

/* CONTENT */

.fitro-scan-content {
    position: relative;
    z-index: 2;
    opacity: 0;
    transform: translateY(25px);
    transition:
        opacity .85s ease,
        transform .85s cubic-bezier(.22, 1, .36, 1);
}

.fitro-body-scan.is-visible .fitro-scan-content {
    opacity: 1;
    transform: translateY(0);
}

.fitro-scan-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    margin-bottom: 28px;
    color: #446DA7;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .2em;
}

.fitro-scan-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #557CB5;
    box-shadow: 0 0 12px rgba(85, 124, 181, .28);
}

.fitro-scan-heading {
    margin: 0;
    font-size: clamp(44px, 5.3vw, 78px);
    line-height: 1.08;
    letter-spacing: -.055em;
    font-weight: 750;
    color: #14243D;
}

.fitro-scan-heading span {
    display: block;
    color: #5277B2;
}

.fitro-scan-description {
    max-width: 445px;
    margin: 26px 0 0;
    color: #62738A;
    font-size: clamp(15px, 1.2vw, 17px);
    line-height: 1.85;
}

.fitro-scan-features {
    display: flex;
    flex-wrap: wrap;
    gap: 13px 22px;
    margin-top: 30px;
}

.fitro-scan-feature {
    display: flex;
    align-items: center;
    gap: 9px;
    color: #34465F;
    font-size: 12px;
    font-weight: 500;
}

.fitro-feature-check {
    color: #517AB4;
    font-size: 15px;
}

.fitro-scan-button {
    margin-top: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 22px;
    min-height: 52px;
    padding: 0 25px;
    border: 1px solid #274B7D;
    border-radius: 8px;
    background: linear-gradient(135deg, #274B7D 0%, #3D69A3 100%);
    color: #FFFFFF;
    font-family: inherit;
    font-size: 13px;
    font-weight: 750;
    cursor: pointer;
    transition:
        transform .3s ease,
        background .3s ease,
        box-shadow .3s ease;
}

.fitro-scan-button:hover {
    transform: translateY(-3px);
    background: linear-gradient(135deg, #345F99 0%, #547FB8 100%);
    box-shadow: 0 12px 36px rgba(39, 75, 125, .20);
}

.fitro-scan-button:focus-visible {
    outline: 2px solid #5277B2;
    outline-offset: 4px;
}

.fitro-scan-caption {
    margin-top: 15px;
    color: #71829A;
    font-size: 11px;
}

/* SCANNER */

.fitro-scan-visual {
    width: 100%;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    opacity: 0;
    transform: translateY(35px) scale(.97);
    transition:
        opacity 1s ease .15s,
        transform 1s cubic-bezier(.22, 1, .36, 1) .15s;
}

.fitro-body-scan.is-visible .fitro-scan-visual {
    opacity: 1;
    transform: none;
}

.fitro-scanner-shell {
    position: relative;
    width: min(100%, 440px);
    height: clamp(420px, 68vh, 620px);
    border: 1px solid rgba(98, 136, 188, .35);
    border-radius: 20px;
    overflow: hidden;
    background:
        radial-gradient(
            ellipse at center,
            rgba(107, 129, 214, .14),
            transparent 66%
        ),
        linear-gradient(160deg, #182C49, #0A1528);
    box-shadow: 0 28px 70px rgba(42, 66, 103, .19), inset 0 1px 0 rgba(211, 224, 255, .06);
}

.fitro-scanner-corners span {
    position: absolute;
    z-index: 5;
    width: 21px;
    height: 21px;
    border-color: #9EB9F8;
    border-style: solid;
}

.fitro-scanner-corners span:nth-child(1) {
    top: 0; left: 0;
    border-width: 2px 0 0 2px;
}

.fitro-scanner-corners span:nth-child(2) {
    top: 0; right: 0;
    border-width: 2px 2px 0 0;
}

.fitro-scanner-corners span:nth-child(3) {
    bottom: 0; left: 0;
    border-width: 0 0 2px 2px;
}

.fitro-scanner-corners span:nth-child(4) {
    bottom: 0; right: 0;
    border-width: 0 2px 2px 0;
}

.fitro-scanner-top,
.fitro-scanner-bottom {
    position: absolute;
    left: 24px;
    right: 24px;
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 9px;
    color: #BAC8DE;
    font-size: 10px;
    font-weight: 650;
    letter-spacing: .12em;
}

.fitro-scanner-top { top: 25px; }
.fitro-scanner-bottom {
    bottom: 23px;
    justify-content: space-between;
}

.fitro-scanner-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #A9C0FF;
}

.fitro-scanner-id {
    margin-left: auto;
    opacity: .55;
}

.fitro-scanner-stage {
    position: absolute;
    inset: 68px 25px 55px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* The SVG silhouette has been replaced with bodyScan.png.
   Keep the original scanner frame and scanning line untouched. */
.fitro-body-scan .fitro-human-model-image {
    position: relative;
    z-index: 2;
    display: block;
    flex: 0 1 auto;
    width: auto;
    height: 96%;
    max-width: 94%;
    max-height: 100%;
    object-fit: contain;
    object-position: center;
    opacity: 1;
    filter: drop-shadow(0 12px 24px rgba(32, 70, 121, .18));
    user-select: none;
    -webkit-user-drag: none;
    pointer-events: none;
}

.fitro-scanner-ring {
    position: absolute;
    width: 86%;
    aspect-ratio: 1;
    border: 1px solid rgba(143, 170, 224, .15);
    border-radius: 50%;
}

.ring-two {
    width: 62%;
    border-style: dashed;
}

.fitro-scan-grid {
    position: absolute;
    inset: 0;
    z-index: 1;
    opacity: .2;
    background-image:
        linear-gradient(rgba(147, 172, 225, .10) 1px, transparent 1px),
        linear-gradient(90deg, rgba(147, 172, 225, .10) 1px, transparent 1px);
    background-size: 28px 28px;
    mask-image: radial-gradient(ellipse, black 25%, transparent 78%);
    pointer-events: none;
}

.fitro-scan-beam {
    position: absolute;
    z-index: 4;
    top: 0;
    left: 4%;
    width: 92%;
    height: 3px;
    opacity: 0;
    background: linear-gradient(90deg, transparent, #79BEEA 18%, #D6E6FF 50%, #79BEEA 82%, transparent);
    box-shadow: 0 0 12px rgba(152, 206, 255, .75), 0 0 28px rgba(120, 164, 245, .32);
    pointer-events: none;
    animation: fitroContinuousScan 5s ease-in-out infinite alternate;
    animation-play-state: paused;
}

.fitro-scan-beam::after {
    content: "";
    position: absolute;
    left: 0;
    top: 3px;
    width: 100%;
    height: 55px;
    background: linear-gradient(to bottom, rgba(125, 175, 250, .15), transparent);
    filter: blur(9px);
}

.fitro-scanner-shell.is-scanning .fitro-scan-beam {
    opacity: 1;
    animation-play-state: running;
}


.fitro-scan-target {
    position: absolute;
    z-index: 3;
    left: 50%;
    transform: translateX(-50%);
    height: 1px;
    width: 80%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(159, 187, 247, .18),
        transparent
    );
}

.target-top { top: 20%; }
.target-bottom { bottom: 18%; }

.fitro-scanner-indicator {
    display: flex;
    gap: 4px;
}

.fitro-scanner-indicator i {
    width: 15px;
    height: 3px;
    background: #4F6288;
    border-radius: 2px;
    animation: fitroIndicator 900ms ease-in-out infinite alternate;
    animation-play-state: paused;
}

.fitro-scanner-shell.is-scanning .fitro-scanner-indicator i {
    animation-play-state: running;
}

.fitro-scanner-indicator i:nth-child(2) {
    animation-delay: 200ms !important;
}

.fitro-scanner-indicator i:nth-child(3) {
    animation-delay: 400ms !important;
}

.fitro-visual-footnote {
    margin-top: 20px;
    color: #60738D;
    font-size: 10px;
    letter-spacing: .15em;
}

.fitro-visual-footnote span {
    color: #3F659C;
}

@keyframes fitroContinuousScan {
    from { top: 0; }
    to { top: calc(100% - 3px); }
}

@keyframes fitroIndicator {
    from { background: #4F6288; }
    to { background: #B9CDFF; }
}

/* RESPONSIVE */

@media (max-width: 900px) {
    .fitro-body-scan {
        padding: 85px 6% 0;
    }

    .fitro-scan-container {
        grid-template-columns: 1fr;
        gap: 50px;
    }

    .fitro-scan-content {
        text-align: center;
    }

    .fitro-scan-description {
        margin-left: auto;
        margin-right: auto;
    }

    .fitro-scan-features {
        justify-content: center;
    }

    .fitro-scanner-shell {
        height: 540px;
    }
}

@media (max-width: 520px) {
    .fitro-body-scan {
        padding: 75px 20px 0;
    }

    .fitro-scan-heading {
        font-size: clamp(40px, 10vw, 54px);
    }

    .fitro-scan-description {
        font-size: 14px;
    }

    .fitro-scan-features {
        gap: 12px 15px;
    }

    .fitro-scan-feature {
        font-size: 11px;
    }

    .fitro-scanner-shell {
        height: 450px;
    }

    .fitro-scanner-stage {
        inset: 62px 17px 51px;
    }

    .fitro-body-scan .fitro-human-model-image {
        height: 94%;
        max-width: 95%;
    }

    .fitro-visual-footnote {
        font-size: 9px;
        text-align: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .fitro-scan-content,
    .fitro-scan-visual {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .fitro-scan-beam,
    .fitro-scanner-indicator i {
        animation: none !important;
    }

    .fitro-scanner-shell.is-scanning .fitro-scan-beam {
        opacity: .55;
        top: 50%;
    }
}

/* Show the content without relying on JS when reduced motion is requested. */
@media (prefers-reduced-motion: reduce) {
  .fitro-body-scan .fitro-scan-content,
  .fitro-body-scan .fitro-scan-visual { opacity: 1; transform: none; }
}

/* =========================================================
   BODY SCAN TRUST MARQUEE — SINGLE CONTINUOUS INFINITE LOOP
   The Blade markup already contains two identical label sequences.
========================================================= */
.fitro-body-scan .fitro-hero-trust-marquee {
    --trust-gap: clamp(22px, 3vw, 42px);
    position: relative;
    align-self: stretch;
    flex: 0 0 auto;
    width: calc(100% + 12vw);
    max-width: none;
    margin: clamp(55px, 7vw, 90px) -6vw 0;
    padding: 22px 0;
    overflow: hidden;
    border-top: 1px solid rgba(47, 75, 112, .12);
    background: rgba(226, 235, 248, .54);
    -webkit-mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent);
    mask-image: linear-gradient(to right, transparent, #000 6%, #000 94%, transparent);
}

.fitro-body-scan .fitro-hero-trust-track {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    width: max-content;
    min-width: max-content;
    gap: var(--trust-gap);
    white-space: nowrap;
    animation: fitroBodyTrustLoop 36s linear infinite;
    will-change: transform;
}

.fitro-body-scan .fitro-hero-trust-track span {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    color: #475E7E;
    font-family: inherit;
    font-size: clamp(10px, .95vw, 12px);
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: .15em;
    text-transform: uppercase;
}

.fitro-body-scan .fitro-hero-trust-track i {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    color: #7390BE;
    font-size: 12px;
    font-weight: 400;
    font-style: normal;
    line-height: 1;
}

/* Half the track plus half an inter-item gap makes the duplicate exact. */
@keyframes fitroBodyTrustLoop {
    from { transform: translate3d(0, 0, 0); }
    to { transform: translate3d(calc(-50% - var(--trust-gap) / 2), 0, 0); }
}

@media (hover: hover) {
    .fitro-body-scan .fitro-hero-trust-marquee:hover .fitro-hero-trust-track {
        animation-play-state: paused;
    }
}

@media (max-width: 900px) {
    .fitro-body-scan .fitro-hero-trust-marquee {
        margin-top: 60px;
        padding: 18px 0;
    }
    .fitro-body-scan .fitro-hero-trust-track {
        animation-duration: 31s;
    }
}

@media (max-width: 520px) {
    .fitro-body-scan .fitro-hero-trust-marquee {
        width: calc(100% + 40px);
        margin: 45px -20px 0;
        padding: 16px 0;
    }
    .fitro-body-scan .fitro-hero-trust-track {
        --trust-gap: 23px;
        animation-duration: 29s;
    }
    .fitro-body-scan .fitro-hero-trust-track span {
        font-size: 10px;
        letter-spacing: .11em;
    }
    .fitro-body-scan .fitro-hero-trust-track i { font-size: 11px; }
}

@media (prefers-reduced-motion: reduce) {
    .fitro-body-scan .fitro-hero-trust-track {
        animation: none !important;
        will-change: auto;
    }
    .fitro-body-scan .fitro-hero-trust-marquee {
        overflow-x: auto;
        -webkit-mask-image: none;
        mask-image: none;
    }
}


/* =====================================================
   FITROAI BODY SCAN — FINAL LAYOUT CORRECTION
===================================================== */

@media (min-width: 901px) {

    #fitroBodyScan .fitro-scan-container {
        display: grid !important;
        grid-template-columns:
            minmax(0, 1.05fr)
            minmax(0, .95fr) !important;

        grid-template-rows: auto !important;

        align-items: center !important;
        column-gap: clamp(35px, 5vw, 90px);

        width: 100%;
        max-width: 1320px;
        margin-inline: auto;
    }

    #fitroBodyScan .fitro-scan-content {
        grid-column: 1 !important;
        grid-row: 1 !important;

        align-self: center;
        min-width: 0;
        width: 100%;
        max-width: 570px;
    }

    #fitroBodyScan .fitro-scan-visual {
        grid-column: 2 !important;
        grid-row: 1 !important;

        align-self: center;
        justify-self: center;

        min-width: 0;
        width: 100%;
        max-width: 500px;
    }

    #fitroBodyScan .fitro-scanner-shell {
        width: min(100%, 440px);
        height: clamp(440px, 65vh, 600px);
        margin-inline: auto;
    }
}

/* Tablet and mobile */

@media (max-width: 900px) {

    #fitroBodyScan .fitro-scan-container {
        display: grid !important;
        grid-template-columns: minmax(0, 1fr) !important;
        grid-template-rows: auto auto !important;
        gap: 40px;
    }

    #fitroBodyScan .fitro-scan-content {
        grid-column: 1 !important;
        grid-row: 1 !important;
        width: 100%;
    }

    #fitroBodyScan .fitro-scan-visual {
        grid-column: 1 !important;
        grid-row: 2 !important;
        width: 100%;
    }
}

/* Image sizing */

#fitroBodyScan .fitro-human-model-image {
    position: relative;
    z-index: 2;

    display: block;
    width: auto;
    height: 96%;

    max-width: 94%;
    max-height: 100%;

    object-fit: contain;
    object-position: center;

    pointer-events: none;
    user-select: none;
}
