/* =========================================================
   ELDER LABORATORIES — HOME LUXE LAYER
   Load AFTER home.css and home-premium.css.
   Delete this file + home-luxe.js to go back to the old look.
   Palette: navy #0a1b33 / brand #234E86 / cyan #147bc1 / gold #c9a24b
   ========================================================= */

:root {
    --luxe-navy: #0a1b33;
    --luxe-brand: #234e86;
    --luxe-cyan: #147bc1;
    --luxe-gold: #c9a24b;
    --luxe-gold-soft: #e8cf8e;
    --luxe-ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- scroll progress (injected by JS) ---------- */
.luxe-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 100%;
    transform-origin: left;
    transform: scaleX(0);
    z-index: 9999;
    background: linear-gradient(90deg, var(--luxe-cyan), var(--luxe-gold));
    pointer-events: none;
}

/* =========================================================
   HERO — the one orchestrated moment
   ========================================================= */
.elder-hero .hero-small-title {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    padding-left: 18px !important;
    color: var(--luxe-brand) !important;
}

/* "Innovation": gradient ink, no glass pill, hand-drawn gold scribble */
.elder-hero .hero-text h1 span {
    background: linear-gradient(100deg, #147bc1 0%, #234e86 55%, #b98a2c 100%) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent;
    color: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    padding: 0 !important;
    margin: 0 !important;
    position: relative;
    display: inline;
}

    .elder-hero .hero-text h1 span::before {
        display: none !important;
    }

    .elder-hero .hero-text h1 span::after {
        display: none !important;
    }

.luxe-scribble {
    position: absolute;
    left: -2%;
    bottom: -18px;
    width: 104%;
    height: 22px;
    overflow: visible;
    pointer-events: none;
    -webkit-text-fill-color: initial;
}

    .luxe-scribble path {
        fill: none;
        stroke: var(--luxe-gold);
        stroke-width: 3.5;
        stroke-linecap: round;
        stroke-dasharray: 420;
        stroke-dashoffset: 420;
        animation: luxeDraw 1.3s .9s var(--luxe-ease) forwards;
    }

        .luxe-scribble path + path {
            stroke: var(--luxe-gold-soft);
            stroke-width: 2;
            animation-delay: 1.15s;
        }

@keyframes luxeDraw {
    to {
        stroke-dashoffset: 0;
    }
}

/* staggered entrance */
.elder-hero .hero-small-title, .elder-hero .hero-text h1,
.elder-hero .hero-text p, .elder-hero .hero-buttons {
    animation: luxeUp 1s var(--luxe-ease) both;
}

.elder-hero .hero-text h1 {
    animation-delay: .15s;
}

.elder-hero .hero-text p {
    animation-delay: .35s;
}

.elder-hero .hero-buttons {
    animation-delay: .5s;
}

@keyframes luxeUp {
    from {
        opacity: 0;
        transform: translateY(26px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

/* slow light sweep across the hero image */
.elder-hero .hero-shapes::before {
    content: "";
    position: absolute;
    inset: -20% auto -20% -40%;
    width: 35%;
    background: linear-gradient(100deg, transparent, rgba(255,255,255,.35), transparent);
    transform: skewX(-18deg);
    animation: luxeSweep 9s 2s ease-in-out infinite;
    pointer-events: none;
}

@keyframes luxeSweep {
    0% {
        left: -40%;
    }

    55%, 100% {
        left: 130%;
    }
}

/* glass orbs: crisper rim + inner sheen */
.elder-hero .hero-3d-shape {
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.55), inset 0 -18px 40px rgba(20,123,193,.25);
    backdrop-filter: blur(3px);
}

.elder-hero .hero-shapes {
    transition: transform .25s ease-out;
    will-change: transform;
}

/* buttons */
.elder-hero .hero-buttons .btn-primary {
    background: linear-gradient(135deg, #147bc1, #234e86 70%) !important;
    box-shadow: 0 12px 28px rgba(35,78,134,.28), inset 0 1px 0 rgba(255,255,255,.25) !important;
}

.elder-hero .hero-buttons .btn-outline {
    border-color: rgba(201,162,75,.65) !important;
}

    .elder-hero .hero-buttons .btn-outline:hover {
        border-color: var(--luxe-gold) !important;
    }

.btn-primary, .btn-outline, .about-button {
    will-change: transform;
}

/* wave: thin navy line + gold highlight */
.elder-hero .hero-bottom-wave .wave-white-highlight {
    stroke: rgba(232,207,142,.9) !important;
    stroke-width: 1.6px !important;
}

/* =========================================================
   SHARED — section headings with drawn gold scribble
   ========================================================= */
.section-heading span, .section-tag {
    color: var(--luxe-brand) !important;
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

    .section-heading span::before, .section-heading span::after, .section-tag::before {
        content: "";
        width: 26px;
        height: 1px;
        background: var(--luxe-gold);
    }

    .section-tag::after {
        display: none;
    }

    .section-heading span::after {
        display: block;
    }

.section-heading h2::after, .about-content h2::after {
    content: "";
    display: block;
    height: 14px;
    width: 190px;
    margin-top: 12px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 190 14'%3E%3Cpath d='M3 9 C35 2 62 12 95 6 S160 3 187 8' fill='none' stroke='%23c9a24b' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat center / 100% 100%;
    clip-path: inset(0 100% 0 0);
    transition: clip-path 1.1s var(--luxe-ease) .2s;
}

.section-heading h2::after {
    margin-left: auto;
    margin-right: auto;
}

.luxe-in h2::after, h2.luxe-in::after {
    clip-path: inset(0 0 0 0);
}

/* =========================================================
   ABOUT
   ========================================================= */
.about-image {
    isolation: isolate;
}

    .about-image::before { /* offset gold frame */
        content: "";
        position: absolute;
        inset: 22px -22px -22px 22px;
        z-index: 1;
        border: 1.5px solid rgba(201,162,75,.7);
        border-radius: 30px;
        transition: transform .6s var(--luxe-ease);
    }

    .about-image::after { /* slow dashed orbit */
        content: "";
        position: absolute;
        width: 150px;
        height: 150px;
        top: -46px;
        left: -46px;
        z-index: 3;
        border: 1.5px dashed rgba(35,78,134,.35);
        border-radius: 50%;
        animation: luxeSpin 40s linear infinite;
        pointer-events: none;
    }

    .about-image:hover::before {
        transform: translate(-8px, -8px);
    }

@keyframes luxeSpin {
    to {
        transform: rotate(360deg);
    }
}

.about-image img {
    box-shadow: 0 40px 80px -20px rgba(10,27,51,.35) !important;
    clip-path: inset(0 100% 0 0 round 30px);
    transition: clip-path 1.2s var(--luxe-ease);
}

.about-image.luxe-in img {
    clip-path: inset(0 0 0 0 round 30px);
}

.about-button, .btn-primary {
    background: linear-gradient(135deg, #147bc1, #234e86) !important;
    position: relative;
    overflow: hidden;
}

    .about-button::before, .btn-primary::before { /* shine */
        content: "";
        position: absolute;
        top: 0;
        bottom: 0;
        left: -80px;
        width: 44px;
        background: linear-gradient(90deg, transparent, rgba(255,255,255,.35), transparent);
        transform: skewX(-20deg);
        transition: left .6s ease;
    }

    .about-button:hover::before, .btn-primary:hover::before {
        left: 120%;
    }

/* =========================================================
   THERAPY — dark navy stage, glass cards
   ========================================================= */
.therapy-section {
    background: radial-gradient(900px 420px at 12% 0%, rgba(20,123,193,.35), transparent 65%), radial-gradient(700px 400px at 95% 100%, rgba(201,162,75,.14), transparent 60%), linear-gradient(165deg, #0a1b33 0%, #0f2b52 55%, #0a1b33 100%) !important;
}

    .therapy-section .therapy-section-bg {
        display: none;
    }

    .therapy-section .section-heading h2 {
        color: #fff;
    }

    .therapy-section .section-heading span {
        color: var(--luxe-gold-soft) !important;
    }

    .therapy-section .section-heading p {
        color: rgba(255,255,255,.72);
    }

.therapy-abstract span {
    border-color: rgba(255,255,255,.16) !important;
}

.therapy-section .hero-3d-shape {
    opacity: .25;
}

.therapy-section .therapy-grid .therapy-card {
    background: rgba(255,255,255,.06) !important;
    border: 1px solid rgba(255,255,255,.14) !important;
    box-shadow: 0 20px 40px -20px rgba(0,0,0,.5), inset 0 1px 0 rgba(255,255,255,.15) !important;
    backdrop-filter: blur(14px);
    overflow: hidden;
}

    .therapy-section .therapy-grid .therapy-card:hover {
        border-color: rgba(201,162,75,.6) !important;
        box-shadow: 0 30px 55px -20px rgba(0,0,0,.65), 0 0 40px rgba(201,162,75,.12), inset 0 1px 0 rgba(255,255,255,.25) !important;
    }

.therapy-card h3 {
    color: #fff !important;
}

.therapy-card p {
    color: rgba(255,255,255,.66) !important;
}

.therapy-icon {
    box-shadow: 0 0 0 6px rgba(255,255,255,.06), 0 0 0 7px rgba(201,162,75,.4);
    background: linear-gradient(145deg, #f4f9ff, #d9e9f8) !important;
}

/* cursor spotlight (both card types) */
.therapy-card::before, .product-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    z-index: 3;
    opacity: 0;
    transition: opacity .35s ease;
    background: radial-gradient(320px circle at var(--mx, 50%) var(--my, 50%), rgba(201,162,75,.16), transparent 60%);
}

.therapy-card:hover::before, .product-card:hover::before {
    opacity: 1;
}

/* one staggered entrance for dynamic cards */
.luxe-card {
    opacity: 0;
    transform: translateY(28px) scale(.98);
}

    .luxe-card.luxe-in {
        opacity: 1;
        transform: none;
        transition: opacity .8s var(--luxe-ease) var(--d, 0s), transform .8s var(--luxe-ease) var(--d, 0s), box-shadow .35s ease, border-color .35s ease;
    }

        .luxe-card.luxe-in:hover {
            transform: translateY(-10px);
            transition-delay: 0s;
        }

/* =========================================================
   FEATURED PRODUCTS
   ========================================================= */
.featured-products {
    background: linear-gradient(180deg, #fff 0%, #f4f8fd 100%) !important;
}

.product-card {
    border: 1px solid rgba(35,78,134,.1) !important;
    box-shadow: 0 1px 0 #fff inset, 0 18px 40px -22px rgba(10,27,51,.28) !important;
}

    .product-card::after { /* gold line grows on hover */
        content: "";
        position: absolute;
        left: 0;
        bottom: 0;
        height: 3px;
        width: 0;
        background: linear-gradient(90deg, var(--luxe-gold), var(--luxe-gold-soft));
        transition: width .6s var(--luxe-ease);
    }

    .product-card:hover::after {
        width: 100%;
    }

.product-image {
    background: radial-gradient(circle at 50% 40%, #fff 0%, #e9f2fb 100%) !important;
}

.product-content span {
    color: var(--luxe-gold) !important;
}

.product-content a {
    position: relative;
}

    .product-content a::after {
        content: "";
        position: absolute;
        left: 0;
        right: 0;
        bottom: -3px;
        height: 1px;
        background: currentColor;
        transform: scaleX(0);
        transform-origin: left;
        transition: transform .4s ease;
    }

    .product-content a:hover::after {
        transform: scaleX(1);
    }

/* =========================================================
   RESPONSIVE + ACCESSIBILITY
   ========================================================= */
@media (max-width: 992px) {
    .about-image::before {
        inset: 14px -10px -14px 14px;
    }

    .about-image::after {
        display: none;
    }

    .section-heading h2::after, .about-content h2::after {
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 576px) {
    .luxe-scribble {
        bottom: -12px;
        height: 16px;
    }

    .elder-hero .hero-shapes::before {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .luxe-scribble path {
        animation: none;
        stroke-dashoffset: 0;
    }

    .elder-hero .hero-small-title, .elder-hero .hero-text h1, .elder-hero .hero-text p,
    .elder-hero .hero-buttons, .about-image::after, .elder-hero .hero-shapes::before {
        animation: none !important;
    }

    .luxe-card, .about-image img, .section-heading h2::after, .about-content h2::after {
        opacity: 1;
        transform: none;
        clip-path: none;
        transition: none;
    }
}

/* =========================================================
   HERO IMAGE POSITIONING (desktop / tablet / mobile)
   ========================================================= */

/* DESKTOP: show more of the top of the image (head + network) */
@media (min-width: 993px) {
    .elder-hero::before {
        background-size: cover !important;
        background-position: center 6% !important;
    }
}

/* TABLET (769–992px): left exactly as it was, it already looks right */

/* MOBILE: image becomes a clean banner on top, text sits below it */
@media (max-width: 768px) {
    .elder-hero {
        min-height: 0 !important;
        background-image: none !important;
        background: #f4f8fc !important;
    }

        .elder-hero::before {
            inset: 0 0 auto 0 !important;
            height: 360px !important;
            background-size: cover !important;
            background-position: 72% 0% !important;
            transform: none !important;
            animation: none !important;
        }

        .elder-hero::after {
            background: linear-gradient(180deg, rgba(244,248,252,0) 0, rgba(244,248,252,0) 210px, #f4f8fc 360px) !important;
        }

        .elder-hero .hero-content {
            min-height: 0 !important;
            justify-content: flex-start !important;
            padding: 290px 20px 90px !important;
            text-align: center;
        }

        .elder-hero .hero-small-title {
            margin-left: auto;
            margin-right: auto;
        }

        /* orbs over text look messy on small screens */
        .elder-hero .hero-shapes {
            display: none !important;
        }

        /* wave must span the viewport, not fixed pixel offsets */
        .elder-hero .hero-bottom-wave {
            left: -10% !important;
            width: 120% !important;
            height: 64px !important;
            bottom: -3px !important;
        }

    .luxe-scribble {
        bottom: -10px;
        height: 14px;
    }
}

@media (max-width: 480px) {
    .elder-hero::before {
        height: 300px !important;
        background-position: 75% 0% !important;
    }

    .elder-hero::after {
        background: linear-gradient(180deg, rgba(244,248,252,0) 0, rgba(244,248,252,0) 170px, #f4f8fc 300px) !important;
    }

    .elder-hero .hero-content {
        padding: 240px 18px 80px !important;
    }

    .elder-hero .hero-bottom-wave {
        height: 52px !important;
    }
}
