/* ============================================================
   main.css — Reset, Variables, Layout global, Nav, Hero, Footer
   XAUUSD Academy
   ============================================================ */

/* -------------------------
   RESET & ROOT VARIABLES
------------------------- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    /* Fondos */
    --bg-deep: #08010f;
    --bg-dark: #0d0118;
    --bg-card: rgba(13, 1, 24, 0.6);

    /* Dorados */
    --gold-bright: #F3D97A;
    --gold-mid: #D4AF37;
    --gold-deep: #9A7B1C;
    --gold-glow: rgba(212, 175, 55, 0.15);
    --gold-glass: rgba(212, 175, 55, 0.06);

    /* Blancos */
    --white: #FAFAF7;
    --white-dim: rgba(250, 250, 247, 0.55);
    --white-faint: rgba(250, 250, 247, 0.12);

    /* Bordes */
    --border-gold: rgba(212, 175, 55, 0.18);
    --border-dim: rgba(250, 250, 247, 0.07);

    /* Velas */
    --green-candle: #2ECC71;
    --red-candle: #E74C3C;

    /* Tipografía */
    --font-title: 'Syne', sans-serif;
    --font-body: 'DM Sans', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
}

html {
    scroll-behavior: smooth;
}

body {
    background: var(--bg-deep);
    color: var(--white);
    font-family: var(--font-body);
    cursor: none;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* -------------------------
   NOISE OVERLAY
------------------------- */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
    opacity: 0.025;
    pointer-events: none;
    z-index: 1;
}

/* -------------------------
   AMBIENT GLOW BLOBS
------------------------- */
.blob {
    position: fixed;
    border-radius: 50%;
    filter: blur(120px);
    pointer-events: none;
    z-index: 0;
}

.blob-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.12) 0%, transparent 70%);
    top: -200px;
    left: -100px;
}

.blob-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(180, 80, 220, 0.06) 0%, transparent 70%);
    bottom: 0;
    right: -100px;
}

.blob-3 {
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.08) 0%, transparent 70%);
    top: 50%;
    left: 60%;
}

/* -------------------------
   NAV
------------------------- */
nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 48px;
    background: rgba(8, 1, 15, 0.5);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-dim);
    transition: padding 0.3s;
}

.nav-logo {
    font-family: var(--font-title);
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.08em;
    color: var(--gold-bright);
    text-decoration: none;
}

.nav-logo span {
    color: var(--white-dim);
    font-weight: 400;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 36px;
    list-style: none;
}

.nav-links a {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--white-dim);
    text-decoration: none;
    transition: color 0.2s;
}

.nav-links a:hover {
    color: var(--gold-bright);
}

.nav-cta {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--gold-mid);
    border: 1px solid var(--border-gold);
    padding: 10px 20px;
    border-radius: 4px;
    text-decoration: none;
    transition: background 0.25s, color 0.25s;
}

.nav-cta:hover {
    background: var(--gold-glass);
    color: var(--gold-bright);
}

/* -------------------------
   HERO SECTION
------------------------- */
#hero {
    position: relative;
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    padding: 120px 48px 80px;
    gap: 60px;
    z-index: 2;
}

.hero-left {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.hero-tag {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--gold-mid);
    opacity: 0;
}

.hero-tag::before {
    content: '';
    display: block;
    width: 32px;
    height: 1px;
    background: var(--gold-mid);
}

.hero-title {
    font-family: var(--font-title);
    font-size: clamp(48px, 6vw, 84px);
    font-weight: 800;
    line-height: 1.0;
    letter-spacing: -0.02em;
    opacity: 0;
}

.hero-title .line {
    display: block;
    overflow: hidden;
}

.hero-title .word-gold {
    color: var(--gold-bright);
}

.hero-title .word-stroke {
    -webkit-text-stroke: 1px rgba(243, 217, 122, 0.4);
    color: transparent;
}

.hero-sub {
    font-size: 17px;
    font-weight: 300;
    line-height: 1.7;
    color: var(--white-dim);
    max-width: 480px;
    opacity: 0;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: 20px;
    opacity: 0;
}

/* Stats row */
.hero-stats {
    display: flex;
    gap: 40px;
    padding-top: 8px;
    opacity: 0;
}

.stat {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-num {
    font-family: var(--font-title);
    font-size: 26px;
    font-weight: 700;
    color: var(--gold-bright);
}

.stat-label {
    font-family: var(--font-mono);
    font-size: 10px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--white-dim);
}

.stat-divider {
    width: 1px;
    background: var(--border-dim);
    align-self: stretch;
}

/* Hero right panel */
.hero-right {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 16px;
    opacity: 0;
}

/* -------------------------
   TICKER
------------------------- */
.ticker-wrap {
    width: 100%;
    overflow: hidden;
    background: rgba(212, 175, 55, 0.05);
    border-top: 1px solid var(--border-gold);
    border-bottom: 1px solid var(--border-gold);
    padding: 10px 0;
    z-index: 2;
    position: relative;
}

.ticker-track {
    display: flex;
    gap: 0;
    animation: ticker 28s linear infinite;
    white-space: nowrap;
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 0 48px;
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.08em;
    color: var(--white-dim);
    border-right: 1px solid var(--border-dim);
}

.ticker-item .up {
    color: var(--green-candle);
}

.ticker-item .down {
    color: var(--red-candle);
}

.ticker-sym {
    color: var(--gold-mid);
    font-weight: 500;
}

/* -------------------------
   SECTION SHARED
------------------------- */
.section-tag {
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--gold-mid);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.section-tag::after {
    content: '';
    flex: 1;
    max-width: 60px;
    height: 1px;
    background: var(--gold-mid);
}

.section-title {
    font-family: var(--font-title);
    font-size: clamp(36px, 4vw, 56px);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.02em;
    margin-bottom: 60px;
}

.section-title span {
    color: var(--gold-bright);
}

/* -------------------------
   WHY SECTION
------------------------- */
#why {
    position: relative;
    z-index: 2;
    padding: 80px 48px 100px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

#why::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent, rgba(212, 175, 55, 0.03), transparent);
    pointer-events: none;
}

.why-left .section-title {
    margin-bottom: 24px;
}

.why-text {
    font-size: 16px;
    font-weight: 300;
    line-height: 1.8;
    color: var(--white-dim);
    margin-bottom: 32px;
}

.why-facts {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.why-fact {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px;
    border: 1px solid var(--border-dim);
    border-radius: 8px;
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    transition: border-color 0.25s;
}

.why-fact:hover {
    border-color: var(--border-gold);
}

.why-fact-icon {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border: 1px solid var(--border-gold);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.why-fact-icon svg {
    width: 18px;
    height: 18px;
}

.why-fact-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.why-fact-title {
    font-family: var(--font-title);
    font-size: 14px;
    font-weight: 600;
}

.why-fact-desc {
    font-size: 13px;
    color: var(--white-dim);
    line-height: 1.5;
}

.why-right {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.why-chart-panel {
    background: var(--bg-card);
    border: 1px solid var(--border-gold);
    border-radius: 12px;
    overflow: hidden;
    backdrop-filter: blur(16px);
    position: relative;
}

.why-chart-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold-mid), transparent);
}

/* -------------------------
   CTA SECTION
------------------------- */
#cta {
    position: relative;
    z-index: 2;
    padding: 100px 48px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 32px;
}

.cta-title {
    font-family: var(--font-title);
    font-size: clamp(40px, 5vw, 72px);
    font-weight: 800;
    letter-spacing: -0.025em;
    line-height: 1.05;
}

.cta-title span {
    color: var(--gold-bright);
}

.cta-sub {
    font-size: 18px;
    font-weight: 300;
    color: var(--white-dim);
    max-width: 520px;
}

.cta-line {
    width: 1px;
    height: 60px;
    background: linear-gradient(to bottom, var(--gold-mid), transparent);
    margin: 0 auto;
}

/* -------------------------
   FOOTER
------------------------- */
footer {
    position: relative;
    z-index: 2;
    padding: 28px 48px;
    border-top: 1px solid var(--border-dim);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.footer-logo {
    font-family: var(--font-title);
    font-size: 15px;
    font-weight: 700;
    color: var(--gold-mid);
}

.footer-copy {
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--white-dim);
}

.footer-disc {
    font-size: 11px;
    color: rgba(250, 250, 247, 0.3);
    max-width: 360px;
    text-align: right;
    line-height: 1.5;
}