:root {
    --bg-navy: #0D0F1C;
    --bg-navy-light: #1A1C2D;
    --brand-blue: #00BFFF;
    --brand-magenta: #C43BFF;
    --brand-gradient: linear-gradient(90deg, var(--brand-blue) 0%, var(--brand-magenta) 100%);
    --text-light: #F0F2FF;
    --text-dark: #0D0F1C;
    --text-secondary: #9B9EBA;
    --border-color: rgba(155, 158, 186, 0.2);
    --font-main: "Albert Sans", sans-serif;
    --header-height-mobile: 80px;
    --header-height-desktop: 90px;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body { background-color: var(--bg-navy); color: var(--text-light); font-family: var(--font-main); line-height: 1.6; overflow-x: hidden; }
body.nav-open { overflow: hidden; }
.container { width: 90%; max-width: 1200px; margin: 0 auto; }
a { color: var(--text-light); text-decoration: none; transition: color 0.2s ease; }
ul, li { list-style: none; }
.section-title { font-size: clamp(2.2rem, 5vw, 3.5rem); font-weight: 700; margin-bottom: 1rem; }
.section-header { text-align: center; margin-bottom: 4rem; max-width: 700px; margin-left: auto; margin-right: auto; }
.section-subtitle { font-size: 1.1rem; color: var(--text-secondary); }

.reveal-child { opacity: 0; transform: translateY(40px); transition: opacity 0.8s cubic-bezier(0.165, 0.84, 0.44, 1), transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1); }
.stagger-reveal.visible .reveal-child { opacity: 1; transform: translateY(0); }
.stagger-reveal.visible .reveal-child:nth-child(2) { transition-delay: 0.1s; }
.stagger-reveal.visible .reveal-child:nth-child(3) { transition-delay: 0.2s; }

.main-header { position: fixed; top: 0; left: 0; width: 100%; z-index: 1000; height: var(--header-height-mobile); transition: background-color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease; }
@media (min-width: 992px) { .main-header { height: var(--header-height-desktop); } }
.main-header.is-top { background-color: transparent; border-color: transparent; }
.main-header:not(.is-top) { background: rgba(13, 15, 28, 0.85); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--border-color); }
.main-header .container { display: flex; justify-content: space-between; align-items: center; height: 100%; }
.logo { display: flex; align-items: center; gap: 0.75rem; font-weight: 600; font-size: 1.2rem; }
.logo img { height: 32px; }

.desktop-nav { display: none; }
@media (min-width: 992px) {
    .main-nav { display: block; flex-grow: 1; }
    .desktop-nav { display: flex; justify-content: flex-end; align-items: center; width: 100%; }
    .desktop-nav > li { position: relative; }
    .desktop-nav > li > a { display: block; padding: 0 1.5rem; font-weight: 500; color: var(--text-secondary); transition: color 0.2s ease; }
    .desktop-nav > li > a:hover { color: var(--text-light); }
    .desktop-nav .has-deskmenu > a::after { content: '▾'; font-size: 0.7em; margin-left: 0.5rem; display: inline-block; transition: transform 0.2s ease; }
    .desktop-nav .has-deskmenu:hover > a::after { transform: rotate(180deg); }
    .header-actions-container { margin-left: 2rem; }
    .header-actions { display: flex; gap: 1rem; }
    .desktop-nav .deskmenu { position: absolute; top: 100%; left: 0; background: var(--bg-navy-light); border: 1px solid var(--border-color); border-radius: 8px; min-width: 220px; padding: 0.75rem; box-shadow: 0 10px 30px rgba(0,0,0,0.2); opacity: 0; visibility: hidden; transform: translateY(10px); transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s; z-index: 100; }
    .desktop-nav > li:hover > .deskmenu { opacity: 1; visibility: visible; transform: translateY(0); }
    .desktop-nav .deskmenu li a { display: block; padding: 0.6rem 1rem; color: var(--text-secondary); border-radius: 4px; transition: background-color 0.2s ease, color 0.2s ease; }
    .desktop-nav .deskmenu li a:hover { background-color: var(--brand-blue); color: var(--text-light); }
}

.menu-toggle { display: block; background: none; border: none; cursor: pointer; padding: 10px; z-index: 9999; }
@media (min-width: 992px) { .menu-toggle { display: none; } }
.hamburger { width: 24px; height: 18px; display: flex; flex-direction: column; justify-content: space-between; }
.hamburger span { width: 100%; height: 2px; background: var(--text-light); transition: all 0.3s ease-in-out; }
.backdrop { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); z-index: 9997; opacity: 0; visibility: hidden; transition: opacity 0.4s ease, visibility 0.4s; }
body.nav-open .backdrop { opacity: 1; visibility: visible; }
.mobile-sidebar { display: flex; flex-direction: column; position: fixed; top: 0; right: 0; width: 80%; max-width: 350px; height: 100%; background-color: var(--bg-navy-light); box-shadow: -10px 0 30px rgba(0,0,0,0.3); transform: translateX(100%); transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94); z-index: 9998; }
body.nav-open .mobile-sidebar { transform: translateX(0); }
.mobile-sidebar-header { display: flex; justify-content: space-between; align-items: center; height: var(--header-height-mobile); padding: 0 1.5rem; background-color: var(--bg-navy); border-bottom: 1px solid var(--border-color); }
.close-menu-btn { background: none; border: none; padding: 10px; cursor: pointer; color: var(--text-secondary); }
.close-menu-btn:hover { color: var(--text-light); }
.mobile-sidebar-links { flex-grow: 1; padding: 1rem 0; list-style: none; overflow-y: auto; }
.mobile-sidebar-links > li > a { display: flex; justify-content: space-between; align-items: center; color: var(--text-light); font-size: 1.2rem; font-weight: 600; padding: 1.25rem 1.5rem; position: relative; }
.has-submenu > a::after { content: '+'; font-size: 1.5rem; font-weight: 300; color: var(--text-secondary); transition: transform 0.3s ease; }
.has-submenu.is-open > a { background-color: rgba(0, 191, 255, 0.1); color: var(--brand-blue); }
.has-submenu.is-open > a::after { transform: rotate(45deg); }
.submenu { list-style: none; max-height: 0; overflow: hidden; transition: max-height 0.4s ease-in-out, padding 0.4s ease-in-out; background-color: rgba(0,0,0,0.2); border-left: 3px solid transparent; }
.has-submenu.is-open .submenu { padding-top: 0.5rem; padding-bottom: 0.5rem; border-left-color: var(--brand-blue); }
.submenu li a { display: block; font-size: 1rem; font-weight: 400; padding: 0.75rem 2.5rem; color: var(--text-secondary); transition: color 0.2s ease, padding-left 0.2s ease; }
.submenu li a:hover { color: var(--text-light); padding-left: 2.75rem; }
.mobile-sidebar-actions { display: flex; flex-direction: column; gap: 1rem; padding: 1.5rem; border-top: 1px solid var(--border-color); }
.mobile-sidebar-actions .btn { width: 100%; text-align: center; }

.btn { display: inline-block; padding: 0.8rem 1.75rem; border-radius: 50px; font-weight: 600; transition: all 0.3s ease; cursor: pointer; border: 1px solid transparent; position: relative; overflow: hidden; }
.btn-large { padding: 1rem 2.5rem; font-size: 1.1rem; }
.btn-primary { background: var(--brand-gradient); color: var(--text-light); }
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 10px 25px -5px rgba(0, 191, 255, 0.3), 0 8px 10px -6px rgba(196, 59, 255, 0.3); }
.btn-secondary { background-color: rgba(255, 255, 255, 0.05); color: var(--text-light); border: 1px solid var(--border-color); }
.btn-secondary:hover { background-color: rgba(255, 255, 255, 0.1); border-color: var(--text-light); }

.region-banner { background-color: #f0b90b; color: var(--text-dark); text-align: center; padding: 0.75rem 1rem; font-weight: 500; font-size: 0.9rem; position: fixed; top: var(--header-height-desktop); width: 100%; z-index: 999; display: flex; justify-content: center; align-items: center; gap: 1rem; transition: top 0.4s ease-in-out; }
.region-banner-close { background: none; border: none; font-size: 1.5rem; line-height: 1; cursor: pointer; color: var(--text-dark); opacity: 0.7; }
.region-banner-close:hover { opacity: 1; }
@media (max-width: 991px) { .region-banner { top: var(--header-height-mobile); } }

.hero-markets { min-height: 100vh; display: flex; align-items: center; position: relative; overflow: hidden; text-align: center; padding-top: var(--header-height-desktop); }
.hero-markets-bg { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-image: url('https://fidescapital.org/images/fides9.jpg'); background-size: cover; background-position: center; animation: kenBurns 20s ease-out infinite; z-index: -2; }
.hero-markets::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(to top, rgba(13, 15, 28, 1) 0%, rgba(13, 15, 28, 0.7) 50%, rgba(13, 15, 28, 1) 100%); z-index: -1; }
@keyframes kenBurns { 0% { transform: scale(1.05) translateX(0); } 50% { transform: scale(1) translateX(-20px); } 100% { transform: scale(1.05) translateX(0); } }
.hero-markets .hero-content { z-index: 2; }
.hero-markets .hero-title { background: var(--brand-gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.hero-subtitle { font-size: clamp(1.1rem, 2.5vw, 1.3rem); color: var(--text-secondary); margin: 0 auto 2.5rem; max-width: 55ch; }
.hero-cta { display: flex; justify-content: center; gap: 1rem; flex-wrap: wrap; }
.floating-assets { position: absolute; top: 0; left: 0; width: 100%; height: 100%; pointer-events: none; }
.floating-asset { position: absolute; background: rgba(26, 28, 45, 0.5); backdrop-filter: blur(5px); border-radius: 50%; display: flex; align-items: center; justify-content: center; animation: float 15s ease-in-out infinite; }
.floating-asset img { width: 60%; height: 60%; opacity: 0.7; }
.floating-asset:nth-child(1) { top: 15%; left: 10%; width: 80px; height: 80px; animation-duration: 12s; }
.floating-asset:nth-child(2) { top: 25%; left: 85%; width: 100px; height: 100px; animation-duration: 18s; animation-delay: -5s; }
.floating-asset:nth-child(3) { top: 70%; left: 5%; width: 60px; height: 60px; animation-duration: 15s; animation-delay: -10s; }
.floating-asset:nth-child(4) { top: 80%; left: 90%; width: 120px; height: 120px; animation-duration: 20s; animation-delay: -3s; }
@keyframes float { 0% { transform: translateY(0px) scale(1); } 50% { transform: translateY(-30px) scale(1.05); } 100% { transform: translateY(0px) scale(1); } }

.section-featured-markets { padding: 7rem 0; background-color: var(--bg-navy-light); }
.markets-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.5rem; }
.market-card { background: var(--bg-navy); border: 1px solid var(--border-color); border-radius: 12px; padding: 1.5rem; transition: transform 0.3s ease, box-shadow 0.3s ease; }
.market-card:hover { transform: translateY(-5px); box-shadow: 0 10px 30px rgba(0,0,0,0.2); border-color: var(--brand-blue); }
.market-header { display: flex; align-items: center; gap: 1rem; margin-bottom: 1.5rem; }
.market-header img { height: 48px; width: 48px; }
.market-name strong { display: block; font-size: 1.2rem; }
.market-name span { color: var(--text-secondary); }
.market-data { display: flex; justify-content: space-between; align-items: flex-end; }
.market-price { font-size: 1.8rem; font-weight: 600; }
.market-change { font-weight: 600; font-size: 1rem; transition: color 0.3s ease; }
.market-change.positive { color: #0ECB81; }
.market-change.negative { color: #F6465D; }
.market-sparkline { margin-top: 1rem; height: 40px; }

.section-benefits { padding: 7rem 0; }
.benefits-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 2rem; margin-top: 4rem; }
.benefit-card { text-align: center; }
.benefit-icon { width: 72px; height: 72px; margin: 0 auto 1.5rem auto; border-radius: 50%; background: linear-gradient(135deg, var(--bg-navy-light), var(--bg-navy)); border: 1px solid var(--border-color); display: flex; align-items: center; justify-content: center; }
.benefit-icon svg { width: 32px; height: 32px; color: var(--brand-blue); }
.benefit-card h3 { font-size: 1.3rem; margin-bottom: 0.5rem; }
.benefit-card p { color: var(--text-secondary); }

.section-how-it-works { padding: 7rem 0; background-color: var(--bg-navy-light); overflow: hidden; }
.how-it-works-grid { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 4rem; }
.how-it-works-image img { width: 100%; border-radius: 16px; box-shadow: 0 20px 50px rgba(0,0,0,0.3); }
.steps-list { position: relative; }
.step-item { display: flex; gap: 1.5rem; position: relative; transition: transform 0.3s ease; }
.step-item:hover { transform: scale(1.02); }
.step-item:not(:last-child) { margin-bottom: 2rem; }
.step-visual { display: flex; flex-direction: column; align-items: center; }
.step-number { font-size: 1.3rem; font-weight: 700; width: 50px; height: 50px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; background: rgba(13, 15, 28, 0.5); border-radius: 50%; position: relative; z-index: 2; transition: box-shadow 0.3s ease; }
.step-number::before { content: ''; position: absolute; inset: -1px; border-radius: 50%; background: var(--brand-gradient); z-index: -1; transition: filter 0.3s ease; }
.step-item:hover .step-number::before { filter: brightness(1.3); }
.step-connector { width: 2px; flex-grow: 1; background: linear-gradient(var(--border-color) 60%, transparent 100%) 0 0 / 2px 8px; margin: 0.5rem 0; }
.step-content h3 { font-size: 1.3rem; margin-bottom: 0.5rem; }
.step-content p { color: var(--text-secondary); }

.section-security-highlight { padding: 7rem 0; text-align: center; }
.security-features { display: flex; justify-content: center; gap: 3rem; margin-top: 4rem; flex-wrap: wrap; }
.security-feature { display: flex; flex-direction: column; align-items: center; gap: 1rem; max-width: 200px; }
.security-feature svg { width: 48px; height: 48px; color: var(--text-secondary); }
.security-feature span { font-weight: 600; }

.section-final-cta { padding: 7rem 0; background: var(--bg-navy-light) url('https://fidescapital.org/images/fides9.jpg') no-repeat center center; background-size: cover; background-blend-mode: overlay; text-align: center; }

@media (max-width: 991px) {
    .how-it-works-grid { grid-template-columns: 1fr; }
    .how-it-works-image { order: -1; margin-bottom: 3rem; }
}