/* AK Services public homepage hero.
   Kept isolated from the authenticated admin and user portal shells. */

body[data-page="home"] .ak-public-home-hero {
    --ak-hero-ink: #09213d;
    --ak-hero-teal: #078c8b;
    --ak-hero-teal-dark: #046e72;
    position: relative;
    isolation: isolate;
    display: grid;
    grid-template-columns: minmax(0, 0.92fr) minmax(420px, 1.08fr);
    align-items: center;
    gap: clamp(1rem, 3vw, 4.5rem);
    min-height: clamp(440px, 42vw, 610px);
    padding: clamp(3.25rem, 6vw, 6.25rem) clamp(1.5rem, 7vw, 7.5rem);
    overflow: hidden;
    color: var(--ak-hero-ink);
    background:
        radial-gradient(circle at 91% 14%, rgba(255, 255, 255, 0.9) 0 5.5rem, transparent 5.6rem),
        radial-gradient(circle at 8% 94%, rgba(255, 255, 255, 0.72) 0 6.5rem, transparent 6.6rem),
        linear-gradient(135deg, #f5fcff 0%, #e8f8ff 44%, #d9f3ff 100%);
    border-bottom: 1px solid rgba(31, 128, 168, 0.16);
}

body[data-page="home"] .ak-public-home-hero::before,
body[data-page="home"] .ak-public-home-hero::after {
    content: "";
    position: absolute;
    z-index: -1;
    border-radius: 50%;
    pointer-events: none;
}

body[data-page="home"] .ak-public-home-hero::before {
    width: clamp(18rem, 35vw, 37rem);
    aspect-ratio: 1;
    top: -46%;
    right: 4%;
    background: rgba(255, 255, 255, 0.42);
}

body[data-page="home"] .ak-public-home-hero::after {
    width: clamp(10rem, 20vw, 19rem);
    aspect-ratio: 1;
    left: -5rem;
    bottom: -9rem;
    border: 2.5rem solid rgba(52, 177, 216, 0.08);
}

body[data-page="home"] .ak-home-hero-copy {
    position: relative;
    z-index: 2;
    width: min(100%, 680px);
}

body[data-page="home"] .ak-home-hero-copy h1 {
    margin: 0;
    color: var(--ak-hero-ink);
    font-size: clamp(2.65rem, 4.65vw, 5.1rem);
    font-weight: 750;
    line-height: 1.04;
    letter-spacing: -0.055em;
    text-wrap: balance;
}

body[data-page="home"] .ak-home-hero-copy h1 span,
body[data-page="home"] .ak-home-hero-copy h1 strong {
    display: block;
}

body[data-page="home"] .ak-home-hero-copy h1 strong {
    margin-top: 0.18em;
    color: var(--ak-hero-teal);
    font-weight: inherit;
}

body[data-page="home"] .ak-home-hero-copy > p {
    width: min(100%, 36rem);
    margin: clamp(1.25rem, 2vw, 1.8rem) 0 0;
    color: #304862;
    font-size: clamp(1rem, 1.25vw, 1.28rem);
    font-weight: 500;
    line-height: 1.7;
}

body[data-page="home"] .ak-home-hero-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    min-height: 56px;
    margin-top: clamp(1.75rem, 3vw, 2.6rem);
    padding: 0.9rem 1.55rem 0.9rem 1.7rem;
    border: 1px solid rgba(255, 255, 255, 0.46);
    border-radius: 14px;
    color: #fff;
    background: linear-gradient(135deg, #089b98 0%, #05787e 100%);
    box-shadow: 0 13px 28px rgba(4, 110, 114, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.26);
    font-size: 1.05rem;
    font-weight: 750;
    line-height: 1;
    text-decoration: none;
    transition: transform 180ms ease, box-shadow 180ms ease, filter 180ms ease;
}

body[data-page="home"] .ak-home-hero-cta svg {
    width: 22px;
    height: 22px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform 180ms ease;
}

body[data-page="home"] .ak-home-hero-cta:hover {
    color: #fff;
    transform: translateY(-2px);
    filter: saturate(1.08);
    box-shadow: 0 18px 34px rgba(4, 110, 114, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

body[data-page="home"] .ak-home-hero-cta:hover svg {
    transform: translateX(3px);
}

body[data-page="home"] .ak-home-hero-cta:focus-visible {
    outline: 3px solid rgba(9, 140, 139, 0.26);
    outline-offset: 4px;
}

body[data-page="home"] .ak-home-hero-visual {
    position: relative;
    z-index: 1;
    display: grid;
    place-items: center;
    align-self: stretch;
    min-width: 0;
}

body[data-page="home"] .ak-home-hero-visual::before {
    content: "";
    position: absolute;
    z-index: -1;
    width: min(92%, 640px);
    height: 42%;
    bottom: 7%;
    border-radius: 50%;
    background: radial-gradient(ellipse, rgba(23, 123, 180, 0.22) 0%, rgba(49, 171, 205, 0.09) 46%, transparent 72%);
    filter: blur(7px);
}

body[data-page="home"] .ak-home-hero-visual img {
    display: block;
    width: min(100%, 720px);
    height: auto;
    max-height: 535px;
    object-fit: contain;
    filter: drop-shadow(0 24px 28px rgba(18, 78, 124, 0.14));
    animation: akHomeHeroFloat 6s ease-in-out infinite;
}

body[data-page="home"] .ak-home-hero-orbit,
body[data-page="home"] .ak-home-hero-spark {
    position: absolute;
    z-index: -1;
    display: block;
    pointer-events: none;
}

body[data-page="home"] .ak-home-hero-orbit {
    border-radius: 50%;
    background: rgba(103, 210, 239, 0.23);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.62), 0 8px 22px rgba(21, 118, 160, 0.12);
}

body[data-page="home"] .ak-home-hero-orbit-one {
    width: 2.2rem;
    height: 2.2rem;
    top: 19%;
    right: 6%;
}

body[data-page="home"] .ak-home-hero-orbit-two {
    width: 1.1rem;
    height: 1.1rem;
    left: 13%;
    bottom: 20%;
}

body[data-page="home"] .ak-home-hero-spark {
    width: 0.72rem;
    height: 0.72rem;
    background: #62c9f1;
    clip-path: polygon(50% 0, 61% 38%, 100% 50%, 61% 62%, 50% 100%, 39% 62%, 0 50%, 39% 38%);
}

body[data-page="home"] .ak-home-hero-spark-one {
    top: 24%;
    left: 16%;
}

body[data-page="home"] .ak-home-hero-spark-two {
    right: 18%;
    bottom: 19%;
    transform: scale(0.75);
}

@keyframes akHomeHeroFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

@media (max-width: 1100px) {
    body[data-page="home"] .ak-public-home-hero {
        grid-template-columns: minmax(0, 0.94fr) minmax(340px, 1.06fr);
        gap: 0.75rem;
        min-height: 470px;
        padding: 3.5rem clamp(1.5rem, 4vw, 3.5rem);
    }

    body[data-page="home"] .ak-home-hero-copy h1 {
        font-size: clamp(2.55rem, 5vw, 4rem);
    }

    body[data-page="home"] .ak-home-hero-visual img {
        max-height: 445px;
    }
}

@media (max-width: 760px) {
    body[data-page="home"] .ak-public-home-hero {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.4rem;
        min-height: auto;
        padding: 2.8rem 1.25rem 1.3rem;
        background:
            radial-gradient(circle at 103% 13%, rgba(255, 255, 255, 0.9) 0 5rem, transparent 5.1rem),
            linear-gradient(150deg, #f7fdff 0%, #e5f7ff 52%, #d8f3ff 100%);
    }

    body[data-page="home"] .ak-home-hero-copy {
        width: 100%;
    }

    body[data-page="home"] .ak-home-hero-copy h1 {
        font-size: clamp(2.35rem, 11vw, 3.25rem);
        line-height: 1.08;
        letter-spacing: -0.048em;
    }

    body[data-page="home"] .ak-home-hero-copy > p {
        width: min(100%, 30rem);
        margin-top: 1.05rem;
        font-size: 1rem;
        line-height: 1.62;
    }

    body[data-page="home"] .ak-home-hero-cta {
        min-height: 52px;
        margin-top: 1.55rem;
        padding: 0.82rem 1.3rem 0.82rem 1.45rem;
        border-radius: 13px;
        font-size: 1rem;
    }

    body[data-page="home"] .ak-home-hero-visual {
        min-height: 300px;
        margin: -0.25rem -0.85rem 0;
    }

    body[data-page="home"] .ak-home-hero-visual img {
        width: min(118%, 560px);
        max-height: 355px;
        filter: drop-shadow(0 18px 22px rgba(18, 78, 124, 0.13));
    }

    body[data-page="home"] .ak-home-hero-orbit-one {
        top: 10%;
        right: 5%;
    }
}

@media (max-width: 390px) {
    body[data-page="home"] .ak-public-home-hero {
        padding-inline: 1rem;
    }

    body[data-page="home"] .ak-home-hero-copy h1 {
        font-size: clamp(2.05rem, 10.7vw, 2.65rem);
    }

    body[data-page="home"] .ak-home-hero-visual {
        min-height: 270px;
    }

    body[data-page="home"] .ak-home-hero-visual img {
        max-height: 305px;
    }
}

@media (prefers-reduced-motion: reduce) {
    body[data-page="home"] .ak-home-hero-visual img {
        animation: none;
    }
}
