
/* ==========================================
   EARNOVA HOMEPAGE
   NAVY • ROYAL BLUE • CHAMPAGNE
   COMPLETE CLEAN STYLESHEET
========================================== */

:root {
    --black: #192D59;
    --black-soft: #243B6B;
    --gold: #3467B2;
    --gold-light: #80B5E8;
    --gold-dark: #254F91;
    --white: #FFFFFF;
    --cream: #FBF8EF;
    --text: #192D59;
    --muted: #718099;
    --border: #E6E6E2;
    --sky: #80B5E8;
    --champagne: #FBF8EF;
    --soft-gold: #F3E9CF;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 85px;
}

body {
    font-family: "Inter", Arial, sans-serif;
    background: var(--champagne);
    color: var(--text);
    line-height: 1.7;
}

a {
    text-decoration: none;
    color: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

.container {
    width: min(1160px, 90%);
    margin: 0 auto;
}

.section {
    padding: 100px 0;
}

:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 4px;
}

/* ==========================================
   HEADER
========================================== */

.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(251, 248, 239, 0.97);
    color: var(--black);
    border-bottom: 1px solid rgba(25, 45, 89, 0.08);
    backdrop-filter: blur(12px);
}

.navbar {
    min-height: 82px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 11px;
    flex-shrink: 0;
}

.brand-icon {
    width: 43px;
    height: 43px;
    border: 2px solid var(--gold);
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: var(--gold);
    font-size: 28px;
    font-weight: 800;
    font-style: italic;
    line-height: 1;
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.4;
}

.brand-text strong {
    font-size: 22px;
    letter-spacing: 2.5px;
    font-weight: 800;
}

.brand-text strong span {
    color: var(--gold);
}

.brand-text small {
    color: var(--muted);
    font-size: 9px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-left: auto;
}

.nav-links a {
    color: var(--black);
    font-size: 12px;
    font-weight: 500;
    white-space: nowrap;
    transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--gold);
}

.navbar .mobile-menu {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-left: 18px;
    flex-shrink: 0;
}

.navbar .auth-text-link {
    display: inline-block;
    width: auto;
    padding: 6px 0;
    background: transparent;
    border: none;
    border-radius: 0;
    color: var(--black);
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
    transition: color 0.2s ease;
}

.navbar .auth-text-link:last-child {
    color: var(--gold);
}

.navbar .auth-text-link:hover {
    color: var(--gold-dark);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.menu-toggle {
    display: none;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 6px 10px;
    color: var(--black);
    font-size: 22px;
    cursor: pointer;
}

/* ==========================================
   BUTTONS
========================================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 10px 18px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.5;
    cursor: pointer;
    transition:
        background 0.25s ease,
        color 0.25s ease,
        transform 0.25s ease;
}

.btn-gold {
    background: var(--gold);
    color: var(--white);
}

.btn-gold:hover {
    background: var(--gold-dark);
    transform: translateY(-2px);
}

.btn-outline {
    background: rgba(255, 255, 255, 0.65);
    color: var(--gold-dark);
    border-color: #A8C5E8;
}

.btn-outline:hover {
    background: #EDF5FF;
}

.btn-large {
    padding: 11px 20px;
    min-height: 42px;
}

/* ==========================================
   HERO
========================================== */

.hero {
    position: relative;
    overflow: hidden;
    isolation: isolate;

    background: linear-gradient(
        120deg,
        #FFFFFF 0%,
        #FFFDF8 38%,
        #FBF8EF 75%,
        #F7F0DF 100%
    );

    color: var(--black);
}

/* Original soft background glow */

.hero::before {
    content: "";
    position: absolute;
    z-index: 0;
    width: 650px;
    height: 650px;
    top: -180px;
    right: -270px;
    border-radius: 50%;

    background: radial-gradient(
        circle,
        rgba(128, 181, 232, 0.18) 0%,
        rgba(52, 103, 178, 0.05) 45%,
        transparent 72%
    );

    pointer-events: none;
    animation: floatGlow 20s ease-in-out infinite alternate;
}

.hero::after {
    content: "";
    position: absolute;
    z-index: 0;
    width: 520px;
    height: 520px;
    left: -230px;
    bottom: -300px;
    border-radius: 50%;

    background: radial-gradient(
        circle,
        rgba(243, 233, 207, 0.65),
        transparent 70%
    );

    pointer-events: none;
    animation: floatGlow 25s ease-in-out infinite alternate-reverse;
}

@keyframes floatGlow {
    from {
        transform: translate(0, 0) scale(1);
    }

    to {
        transform: translate(-35px, 25px) scale(1.12);
    }
}

/* Old candlestick canvas disabled */

#marketBackground {
    display: none;
}

/* Hero content above background */

.hero > .hero-content {
    position: relative;
    z-index: 2;
}

.hero-content {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    align-items: center;
    min-height: 560px;
    gap: 50px;
}

.hero-text {
    padding: 90px 0;
}

.eyebrow {
    display: inline-block;
    margin-bottom: 16px;
    color: var(--gold);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2.5px;
}

.hero h1 {
    max-width: 670px;
    font-size: clamp(38px, 4.5vw, 58px);
    line-height: 1.15;
    letter-spacing: -2px;
    font-weight: 800;
    margin-bottom: 24px;
}

.hero h1 span,
.cta-content h2 span {
    color: var(--gold);
}

.hero-text > p {
    max-width: 520px;
    color: #60718A;
    font-size: 14px;
    line-height: 1.95;
    margin-bottom: 30px;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.hero-points {
    display: flex;
    flex-wrap: wrap;
    gap: 22px;
    margin-top: 32px;
    color: #60718A;
    font-size: 11px;
}

/* ==========================================
   EARNOVA ROTATING SPIRAL GALAXY
   NAVY • ROYAL BLUE • CHAMPAGNE
========================================== */

.hero-image {
    position: relative;
    min-height: 400px;
    align-self: center;
    display: grid;
    place-items: center;
    isolation: isolate;
    border-radius: 50%;

    background: radial-gradient(
        circle,
        rgba(255, 255, 255, 0.95) 0%,
        rgba(128, 181, 232, 0.22) 5%,
        rgba(52, 103, 178, 0.10) 18%,
        transparent 60%
    );
}

/* Outer spiral galaxy */

.hero-image::before {
    content: "";
    position: absolute;
    width: min(390px, 88%);
    aspect-ratio: 1;
    border-radius: 50%;

    background:
        radial-gradient(
            ellipse 55% 12% at 50% 50%,
            rgba(128, 181, 232, 0.75),
            transparent 85%
        ),
        conic-gradient(
            from 20deg,
            transparent 0deg,
            rgba(52, 103, 178, 0.08) 25deg,
            rgba(52, 103, 178, 0.65) 55deg,
            rgba(128, 181, 232, 0.18) 85deg,
            transparent 120deg,
            rgba(128, 181, 232, 0.55) 165deg,
            transparent 210deg,
            rgba(52, 103, 178, 0.60) 275deg,
            transparent 330deg,
            transparent 360deg
        );

    -webkit-mask-image: radial-gradient(
        circle,
        transparent 0%,
        black 10%,
        black 68%,
        transparent 84%
    );

    mask-image: radial-gradient(
        circle,
        transparent 0%,
        black 10%,
        black 68%,
        transparent 84%
    );

    filter: drop-shadow(0 0 18px rgba(52, 103, 178, 0.30));

    animation: earnovaGalaxyRotate 35s linear infinite;
}

/* Inner galaxy and glowing stars */

.hero-image::after {
    content: "";
    position: absolute;
    width: min(350px, 64%);
    aspect-ratio: 1;
    border-radius: 50%;

    background:
        radial-gradient(
            circle at 50% 50%,
            #FFFFFF 0%,
            #FBF8EF 3%,
            #80B5E8 8%,
            rgba(52, 103, 178, 0.35) 16%,
            transparent 35%
        ),
        radial-gradient(
            circle at 20% 35%,
            #FFFFFF 0 1px,
            transparent 3px
        ),
        radial-gradient(
            circle at 75% 25%,
            #80B5E8 0 2px,
            transparent 4px
        ),
        radial-gradient(
            circle at 80% 70%,
            #FFFFFF 0 1px,
            transparent 3px
        ),
        radial-gradient(
            circle at 30% 78%,
            #3467B2 0 2px,
            transparent 4px
        ),
        radial-gradient(
            circle at 15% 60%,
            #80B5E8 0 1px,
            transparent 3px
        ),
        conic-gradient(
            from 45deg,
            transparent,
            rgba(128, 181, 232, 0.35),
            transparent,
            rgba(52, 103, 178, 0.35),
            transparent
        );

    box-shadow:
        0 0 35px rgba(128, 181, 232, 0.18),
        inset 0 0 45px rgba(128, 181, 232, 0.12);

    animation: earnovaGalaxyInnerRotate 25s linear infinite;
}

/* Smooth continuous rotation */

@keyframes earnovaGalaxyRotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes earnovaGalaxyInnerRotate {
    from {
        transform: rotate(360deg);
    }

    to {
        transform: rotate(0deg);
    }
}

/* Keep original hero label hidden */

.image-label {
    display: none;
}

/* Respect reduced-motion preferences */

@media (prefers-reduced-motion: reduce) {
    .hero-image::before,
    .hero-image::after {
        animation: none;
    }
}

/* ==========================================
   EARNOVA ANIMATED FALLING LIGHT TRAILS
   ROYAL BLUE • SKY BLUE • SOFT INDIGO
========================================== */

/*
   The trail layer sits above the hero background
   and behind the interactive hero content.

   It is positioned directly inside .hero.
*/

.hero > .earnova-light-trails {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: block;
    overflow: hidden;
    pointer-events: none;
}

/* Shared trail design */

.light-trail {
    --trail-color: 52, 103, 178;

    position: absolute;
    top: 0;
    display: block;
    width: 4px;
    height: 110px;
    border-radius: 999px;

    opacity: 0;
    transform-origin: top center;
    will-change: transform, opacity;

    background: linear-gradient(
        to bottom,
        rgba(var(--trail-color), 1) 0%,
        rgba(var(--trail-color), 0.95) 8%,
        transparent 10%,
        transparent 15%,
        rgba(var(--trail-color), 0.90) 17%,
        transparent 21%,
        rgba(var(--trail-color), 0.75) 26%,
        transparent 31%,
        rgba(var(--trail-color), 0.65) 37%,
        rgba(var(--trail-color), 0.50) 65%,
        transparent 100%
    );

    filter: drop-shadow(
        0 0 7px rgba(var(--trail-color), 0.55)
    );
}

/* Glowing leading head */

.light-trail::before {
    content: "";
    position: absolute;
    top: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 8px;
    height: 11px;
    border-radius: 999px;

    background: rgba(var(--trail-color), 1);

    box-shadow:
        0 0 9px rgba(var(--trail-color), 0.65),
        0 0 17px rgba(var(--trail-color), 0.30);
}

/* LEFT — Royal blue */

.light-trail-left {
    --trail-color: 52, 103, 178;
    left: 27%;

    animation:
        earnovaTrailLeft 26s ease-in-out -9s infinite;
}

/* CENTER — Sky blue */

.light-trail-center {
    --trail-color: 128, 181, 232;
    left: 50%;

    animation:
        earnovaTrailCenter 31s ease-in-out -15s infinite;
}

/* RIGHT — Soft indigo */

.light-trail-right {
    --trail-color: 87, 124, 196;
    left: 74%;

    animation:
        earnovaTrailRight 29s ease-in-out -20s infinite;
}

/* ==========================================
   LEFT TRAIL
   Curved gradual descent
========================================== */

@keyframes earnovaTrailLeft {
    0%, 7% {
        transform:
            translate3d(-15px, -110px, 0)
            scaleY(0.08);
        opacity: 0;
    }

    13% {
        transform:
            translate3d(-12px, -45px, 0)
            scaleY(0.25);
        opacity: 0.55;
    }

    22% {
        transform:
            translate3d(-5px, 65px, 0)
            scaleY(0.7);
        opacity: 0.85;
    }

    40% {
        transform:
            translate3d(12px, 250px, 0)
            scaleY(1);
        opacity: 1;
    }

    58% {
        transform:
            translate3d(2px, 450px, 0)
            scaleY(0.8);
        opacity: 0.65;
    }

    72%, 100% {
        transform:
            translate3d(-10px, 720px, 0)
            scaleY(0.15);
        opacity: 0;
    }
}

/* ==========================================
   CENTER TRAIL
   Nearly vertical descent
========================================== */

@keyframes earnovaTrailCenter {
    0%, 19% {
        transform:
            translate3d(0, -110px, 0)
            scaleY(0.08);
        opacity: 0;
    }

    26% {
        transform:
            translate3d(2px, -35px, 0)
            scaleY(0.3);
        opacity: 0.60;
    }

    35% {
        transform:
            translate3d(-2px, 90px, 0)
            scaleY(0.7);
        opacity: 0.90;
    }

    52% {
        transform:
            translate3d(3px, 290px, 0)
            scaleY(1);
        opacity: 1;
    }

    69% {
        transform:
            translate3d(0, 500px, 0)
            scaleY(0.75);
        opacity: 0.60;
    }

    82%, 100% {
        transform:
            translate3d(0, 720px, 0)
            scaleY(0.12);
        opacity: 0;
    }
}

/* ==========================================
   RIGHT TRAIL
   Gentle sideways drift
========================================== */

@keyframes earnovaTrailRight {
    0%, 31% {
        transform:
            translate3d(12px, -110px, 0)
            scaleY(0.08);
        opacity: 0;
    }

    37% {
        transform:
            translate3d(9px, -35px, 0)
            scaleY(0.3);
        opacity: 0.60;
    }

    46% {
        transform:
            translate3d(2px, 100px, 0)
            scaleY(0.75);
        opacity: 0.90;
    }

    62% {
        transform:
            translate3d(-12px, 300px, 0)
            scaleY(1);
        opacity: 1;
    }

    77% {
        transform:
            translate3d(-3px, 510px, 0)
            scaleY(0.7);
        opacity: 0.55;
    }

    89%, 100% {
        transform:
            translate3d(10px, 720px, 0)
            scaleY(0.12);
        opacity: 0;
    }
}

/* ==========================================
   SECTION HEADINGS
========================================== */

.section-heading {
    text-align: center;
    max-width: 650px;
    margin: 0 auto 52px;
}

.section-heading .eyebrow {
    margin-bottom: 9px;
}

.section-heading h2 {
    color: var(--black);
    font-size: clamp(26px, 3vw, 36px);
    line-height: 1.3;
    letter-spacing: -1px;
    margin-bottom: 13px;
}

.section-heading p {
    color: var(--muted);
    font-size: 14px;
}

/* ==========================================
   FEATURES
========================================== */

.features {
    background: linear-gradient(
        180deg,
        #FBF8EF 0%,
        #F8F5ED 100%
    );
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 22px;
}

.feature-card {
    padding: 30px 24px;
    border: 1px solid #E9E5DB;
    border-radius: 14px;
    background: var(--white);

    transition:
        transform 0.25s ease,
        border-color 0.25s ease,
        box-shadow 0.25s ease;
}

.feature-card:hover {
    transform: translateY(-4px);
    border-color: #B6CCE8;
    box-shadow: 0 12px 28px rgba(25, 45, 89, 0.06);
}

.feature-icon {
    width: 52px;
    height: 52px;
    border-radius: 13px;
    display: grid;
    place-items: center;
    background: #EDF5FF;
    border: 1px solid #DCE9F8;
    color: var(--gold);
    font-size: 26px;
    margin-bottom: 22px;
}

.feature-card h3 {
    color: var(--black);
    font-size: 16px;
    margin-bottom: 12px;
}

.feature-card p {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.9;
    margin-bottom: 20px;
}

.feature-card > a {
    color: var(--gold);
    font-size: 12px;
    font-weight: 600;
}

.feature-card > a:hover {
    color: var(--gold-dark);
}

.feature-card > a span {
    margin-left: 5px;
}

/* ==========================================
   HOW IT WORKS
========================================== */

.how-it-works {
    background: #FFFDF8;
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 25px;
}

.step {
    text-align: center;
    padding: 15px 12px;
}

.step-number {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 1px solid #C7DBF2;
    background: #EDF5FF;
    color: var(--gold);
    display: grid;
    place-items: center;
    margin: 0 auto 22px;
    font-size: 19px;
    font-weight: 700;
}

.step h3 {
    color: var(--black);
    font-size: 15px;
    margin-bottom: 10px;
}

.step p {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.9;
}

/* ==========================================
   CALL TO ACTION
========================================== */

.cta-section {
    background: linear-gradient(
        110deg,
        #F7F0DF 0%,
        #FBF8EF 55%,
        #F2F6FC 100%
    );

    color: var(--black);
    border-top: 1px solid #EAE5D9;
    border-bottom: 1px solid #EAE5D9;
    padding: 65px 0;
}

.cta-content {
    display: grid;
    grid-template-columns: 1fr 1fr auto;
    align-items: center;
    gap: 35px;
}

.cta-content .eyebrow {
    margin-bottom: 8px;
}

.cta-content h2 {
    font-size: clamp(27px, 3vw, 37px);
    line-height: 1.25;
    letter-spacing: -1px;
}

.cta-content > p {
    color: #60718A;
    font-size: 13px;
    line-height: 1.9;
    max-width: 340px;
}

/* ==========================================
   FOOTER
========================================== */

.footer {
    background: var(--black);
    color: var(--white);
}

.footer-main {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 25px;
    padding-top: 38px;
    padding-bottom: 32px;
}

.footer-links {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-links a,
.contact-link {
    font-size: 11px;
    color: #DCE5F2;
    transition: color 0.2s ease;
}

.footer-links a:hover,
.contact-link:hover {
    color: var(--gold-light);
}

.contact-link {
    color: #A8CFFF;
}

.footer .brand-text small {
    color: #C1CBE0;
}

.footer .brand-text strong {
    color: var(--white);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    padding-top: 18px;
    padding-bottom: 18px;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    color: #C1CBE0;
    font-size: 10px;
}

/* ==========================================
   TABLET
========================================== */

@media (max-width: 1050px) {
    .navbar {
        gap: 14px;
    }

    .nav-links {
        gap: 14px;
    }

    .nav-links a {
        font-size: 11px;
    }

    .brand-text strong {
        font-size: 19px;
    }

    .navbar .mobile-menu {
        gap: 13px;
        margin-left: 5px;
    }

    .feature-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .cta-content {
        grid-template-columns: 1fr 1fr;
    }

    .cta-content .btn {
        justify-self: start;
    }
}

/* ==========================================
   MOBILE
========================================== */

@media (max-width: 760px) {
    .navbar {
        min-height: 75px;
    }

    .brand-icon {
        width: 37px;
        height: 37px;
        font-size: 25px;
    }

    .brand-text strong {
        font-size: 17px;
        letter-spacing: 2px;
    }

    .brand-text small {
        font-size: 8px;
    }

    .nav-links,
    .nav-actions {
        display: none;
    }

    .menu-toggle {
        display: block;
        margin-left: auto;
    }

    .navbar .mobile-menu {
        display: none;
        position: absolute;
        top: 75px;
        right: 5%;
        left: auto;
        width: 150px;
        padding: 12px 16px;
        margin-left: 0;
        background: var(--champagne);
        border: 1px solid var(--border);
        border-radius: 10px;
        box-shadow: 0 12px 30px rgba(25, 45, 89, 0.12);
        flex-direction: column;
        align-items: stretch;
        gap: 5px;
    }

    .navbar .mobile-menu.show {
        display: flex;
    }

    .navbar .auth-text-link {
        padding: 9px 4px;
        text-align: left;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 0;
        min-height: auto;
    }

    .hero-text {
        padding: 75px 0 45px;
    }

    .hero h1 {
        font-size: clamp(35px, 8vw, 48px);
        letter-spacing: -1.5px;
    }

    .hero-image {
        min-height: 220px;
        margin-bottom: 35px;
    }

    .hero-image::before {
        width: 190px;
    }

    .hero-image::after {
        width: 135px;
    }

    .light-trail-left {
        left: 16%;
    }

    .light-trail-center {
        left: 50%;
    }

    .light-trail-right {
        left: 84%;
    }

    .light-trail {
        width: 3px;
        height: 85px;
    }

    .light-trail::before {
        width: 7px;
        height: 9px;
    }

    .section {
        padding: 70px 0;
    }

    .section-heading {
        margin-bottom: 35px;
    }

    .feature-grid {
        gap: 14px;
    }

    .feature-card {
        padding: 23px 19px;
    }

    .feature-card h3 {
        font-size: 14px;
    }

    .steps-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 22px 12px;
    }

    .cta-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .cta-content > p {
        max-width: 100%;
    }

    .footer-main {
        flex-direction: column;
        align-items: flex-start;
    }

    .footer-links {
        gap: 14px;
    }
}

@media (max-width: 400px) {
    .brand-text strong {
        font-size: 15px;
    }

    .brand-text small {
        max-width: 145px;
        font-size: 7px;
    }

    .hero-buttons .btn {
        padding: 10px 15px;
    }

    .hero-points {
        gap: 10px;
        font-size: 10px;
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 8px;
    }
}

/* ==========================================
   ACCESSIBILITY
========================================== */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .hero::before,
    .hero::after,
    .hero-image::before,
    .hero-image::after {
        animation: none;
    }

    .light-trail {
        animation: none !important;
        opacity: 0;
    }
}
