/* ================================================================
   OLD MONEY × INSTITUTIONAL FINTECH
   World Map · Manhattan Skyline · Brass Clocks · Gold Palette
   ================================================================ */

/* ── Gold palette ───────────────────────────────────────────── */
:root {
    --gold:        #C8A96A;
    --gold-light:  #E2CC8C;
    --gold-dim:    rgba(200,169,106,0.12);
    --gold-grad:   linear-gradient(135deg, #C8A96A 0%, #E2CC8C 55%, #C8A96A 100%);
    --gold-border: rgba(200,169,106,0.22);
    --gold-glow:   rgba(200,169,106,0.18);
}

/* ── Suppress light mesh blobs on home page — map provides the atmosphere */
body[data-bg="world"] .bg-mesh::before,
body[data-bg="world"] .bg-mesh::after {
    opacity: 0 !important;
    animation: none !important;
}

/* ── Body base matches map dark gray so no tone contrast bleeds */
body[data-bg="world"] {
    background: #181b1f !important;
}

/* ── World canvas (fixed, behind everything) ────────────────── */
#worldBgCanvas {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    pointer-events: none;
    display: block;
    transition: opacity 0.25s ease;
}

/* ── Leaflet map div — fixed between dark canvas (z:0) and sections (z:2) */
#arcgisMap {
    position: fixed;
    top: 0; left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    border: none;
    pointer-events: none;
    display: block;
    transition: opacity 0.25s ease;
    background: #181b1f; /* dark fallback before tiles load */
}

/* Override Leaflet's default #ddd container background */
#arcgisMap .leaflet-container {
    background: #181b1f !important;
}
#arcgisMap .leaflet-tile-pane {
    opacity: 1;
}

/* ── Ensure all page sections sit above the canvas ──────────── */
.nav        { z-index: 1000 !important; }
section,
.hero,
.clock-strip,
.ticker-wrap,
footer      { position: relative; z-index: 2; }

/* ── Hero breathing room + left bias ────────────────────────── */
.hero {
    min-height: unset !important;
    padding-bottom: 72px !important;
}
body[data-bg="world"] .hero .container {
    margin-left: max(24px, 5%) !important;
    margin-right: auto !important;
}

/* ── Terminal chart panels ───────────────────────────────────── */
.hero-charts {
    display: flex;
    flex-direction: column;
    gap: 11px;
}
.terminal-panel {
    background: rgba(10, 15, 23, 0.80);
    border: 1px solid rgba(200,169,106,0.14);
    border-radius: 5px;
    padding: 12px 14px 8px;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 4px 28px rgba(0,0,0,0.50),
                inset 0 1px 0 rgba(200,169,106,0.06);
}
.tp-header {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 4px;
}
.tp-symbol {
    font-family: 'JetBrains Mono', 'SF Mono', monospace;
    font-size: 0.60rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    color: rgba(200,169,106,0.90);
    text-transform: uppercase;
}
.tp-sub {
    font-family: 'JetBrains Mono', 'SF Mono', monospace;
    font-size: 0.47rem;
    color: rgba(255,255,255,0.22);
    letter-spacing: 0.10em;
    text-transform: uppercase;
}
.tp-value-row {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 8px;
}
.tp-value {
    font-family: 'JetBrains Mono', 'SF Mono', monospace;
    font-size: 1.08rem;
    font-weight: 600;
    color: #dce3ee;
    letter-spacing: 0.02em;
}
.tp-chg {
    font-family: 'JetBrains Mono', 'SF Mono', monospace;
    font-size: 0.63rem;
    font-weight: 600;
    letter-spacing: 0.03em;
}
.tp-up   { color: #2ECC71; }
.tp-down { color: #E04F5F; }
.tp-canvas {
    width: 100%;
    height: 56px;
    display: block;
}

/* ── Exchange node markers — CSS-pulsing divIcons ────────────── */
.exch-marker-wrap {
    background: transparent !important;
    border: none !important;
}
.exch-node {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--nc);
    position: relative;
    margin: 6px;
    float: left;
}
.exch-label {
    display: inline-block;
    margin-left: 4px;
    font-family: 'JetBrains Mono', 'SF Mono', monospace;
    font-size: 0.48rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(220, 227, 238, 0.70);
    white-space: nowrap;
    line-height: 20px;
    text-shadow: 0 1px 4px rgba(0,0,0,0.9);
    pointer-events: none;
}
.exch-node.exch-open   { box-shadow: 0 0 8px 2px rgba(46,204,113,0.55); }
.exch-node.exch-closed { box-shadow: 0 0 5px 1px rgba(224,79,95,0.40); }
.exch-node.exch-pre    { box-shadow: 0 0 5px 1px rgba(255,183,77,0.40); }
.exch-node::after {
    content: '';
    position: absolute;
    inset: -7px;
    border-radius: 50%;
    border: 1px solid var(--nc);
    opacity: 0;
    animation: exchPulse 3s ease-out infinite;
}
.exch-node.exch-open::after  { animation-duration: 2.4s; }
.exch-node.exch-closed::after { animation-duration: 5s; }
@keyframes exchPulse {
    0%   { transform: scale(0.3); opacity: 0.85; }
    75%  { transform: scale(2.6); opacity: 0; }
    100% { transform: scale(2.6); opacity: 0; }
}

/* ── Gold text-gradient overrides ──────────────────────────── */
.hero .text-gradient,
.page-header .text-gradient {
    background: var(--gold-grad);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── Section labels — gold ──────────────────────────────────── */
.section-label {
    color: var(--gold);
    animation: goldLabelPulse 4s ease-in-out infinite;
}
@keyframes goldLabelPulse {
    0%,100% { text-shadow: 0 0 0 transparent; }
    50%      { text-shadow: 0 0 18px rgba(200,169,106,0.5); }
}

/* ── Glass card gold border ─────────────────────────────────── */
.glass-card::before {
    background: linear-gradient(90deg, transparent, rgba(200,169,106,0.25), transparent) !important;
}
.glass-card:hover {
    border-color: var(--gold-border) !important;
    box-shadow:
        0 0 0 1px rgba(200,169,106,0.12),
        0 24px 64px rgba(0,0,0,0.45),
        0 0 40px rgba(200,169,106,0.06) !important;
}

/* ── CTA gold ───────────────────────────────────────────────── */
.btn-primary,
.btn-primary::after { background: var(--gold-grad) !important; }
.btn-primary { color: #0a0c14 !important; box-shadow: 0 4px 24px rgba(200,169,106,0.3) !important; }
.btn-primary:hover { box-shadow: 0 8px 36px rgba(200,169,106,0.45) !important; }

/* ── Hero stats gold ────────────────────────────────────────── */
.hero-stat h3 {
    background: var(--gold-grad);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── Hero 2-col: columns illustration ──────────────────────── */
.hero-illustration {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 28px;
}
.hero-columns-svg {
    width: 100%;
    max-width: 400px;
    filter: drop-shadow(0 0 40px rgba(200,169,106,0.12));
    animation: columnsFloat 9s ease-in-out infinite;
}
@keyframes columnsFloat {
    0%,100% { transform: translateY(0); }
    50%      { transform: translateY(-12px); }
}

/* ── ================================================================
   CLOCK STRIP — Institutional Trading Floor Style
   ================================================================ */
.clock-strip {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: clamp(24px, 4vw, 56px);
    padding: 40px 32px 44px;
    position: relative;
    z-index: 2;
    flex-wrap: wrap;

    /* Brass rule top only — bottom is handled by section below */
    border-top:    1px solid rgba(200,169,106,0.12);
    border-bottom: none;

    /* Dark gradient so clocks sit on the map naturally */
    background: linear-gradient(
        to bottom,
        rgba(24,27,31,0.0)  0%,
        rgba(24,27,31,0.82) 40%,
        rgba(24,27,31,0.92) 100%
    );
}

/* "GLOBAL MARKETS" label removed */
.clock-strip::before { display: none; }

/* Individual clock item */
.market-clock {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    position: relative;
    padding: 0 12px;
}

/* Hairline divider between clocks */
.market-clock + .market-clock::before {
    content: '';
    position: absolute;
    left: -1px;
    top: 10%;
    height: 80%;
    width: 1px;
    background: linear-gradient(
        to bottom,
        transparent,
        rgba(200,169,106,0.18),
        transparent
    );
}

/* Canvas — no extra border; the JS draws the bezel */
.market-clock canvas {
    border-radius: 50%;
    display: block;
    /* Subtle shadow for depth */
    filter: drop-shadow(0 4px 18px rgba(0,0,0,0.65))
            drop-shadow(0 0 12px rgba(200,169,106,0.12));
    transition: filter 0.3s ease;
}
.market-clock:hover canvas {
    filter: drop-shadow(0 4px 24px rgba(0,0,0,0.8))
            drop-shadow(0 0 22px rgba(200,169,106,0.28));
}

/* City name */
.clock-city {
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: rgba(200,169,106,0.75);
    margin-top: 4px;
}

/* Exchange code */
.clock-exch {
    font-size: 0.56rem;
    letter-spacing: 0.1em;
    color: rgba(255,255,255,0.25);
    text-transform: uppercase;
}

/* Digital time readout */
.clock-time-digital {
    font-size: 0.85rem;
    font-variant-numeric: tabular-nums;
    font-weight: 600;
    letter-spacing: 0.08em;
    color: rgba(226,204,140,0.82);
    font-family: 'JetBrains Mono', 'SF Mono', 'Fira Mono', monospace;
}

/* Open / Closed status */
.clock-status {
    font-size: 0.52rem;
    font-weight: 800;
    letter-spacing: 0.13em;
    text-transform: uppercase;
    margin-top: 1px;
    white-space: nowrap;
}
.clock-status.open   { color: #00e676; text-shadow: 0 0 10px rgba(0,230,118,0.65); }
.clock-status.pre    { color: #ffb74d; text-shadow: 0 0 8px  rgba(255,183,77,0.5); }
.clock-status.post   { color: rgba(255,183,77,0.55); }
.clock-status.closed { color: rgba(239,68,68,0.65); text-shadow: 0 0 8px rgba(239,68,68,0.35); }

/* ── World Map Window — contains its own canvas ─────────────── */
.world-map-window {
    position: relative;
    z-index: 2;
    height: 520px;
    background: #060B14;
    border-top:    1px solid var(--gold-border);
    border-bottom: 1px solid var(--gold-border);
    overflow: hidden;
}
.world-map-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
}
.world-map-window-header {
    position: absolute;
    top: 0; left: 0; right: 0;
    padding: 14px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: linear-gradient(to bottom, rgba(6,11,20,0.72) 0%, transparent 100%);
    z-index: 3;
    pointer-events: none;
}
.world-map-label {
    font-family: 'JetBrains Mono', 'SF Mono', monospace;
    font-size: 0.6rem;
    font-weight: 800;
    letter-spacing: 0.28em;
    color: var(--gold);
    text-transform: uppercase;
}
.world-map-meta {
    font-family: 'JetBrains Mono', 'SF Mono', monospace;
    font-size: 0.55rem;
    letter-spacing: 0.12em;
    color: rgba(200,169,106,0.45);
    text-transform: uppercase;
}

/* ── Decorative gold rules between sections ──────────────────── */
section + section::before {
    content: '';
    display: block;
    width: 80px;
    height: 1px;
    background: var(--gold-grad);
    margin: 0 auto;
    opacity: 0.35;
}

/* ── CTA section gold ───────────────────────────────────────── */
.cta-inner::before {
    background: radial-gradient(ellipse at center, rgba(200,169,106,0.07), transparent 70%) !important;
}
.cta-inner {
    border-color: var(--gold-border) !important;
}

/* ── Page header gold glow ──────────────────────────────────── */
.page-header::before {
    background: radial-gradient(ellipse at top center, rgba(200,169,106,0.06), transparent 60%) !important;
}

/* ── Wall Street SVG sketch watermark ───────────────────────── */
.ws-watermark {
    position: absolute;
    pointer-events: none;
    opacity: 0.03;
    z-index: 0;
}

/* ── Responsive: stack clocks on mobile ─────────────────────── */
@media (max-width: 640px) {
    .clock-strip {
        gap: 18px;
        padding: 28px 16px 32px;
    }
    .market-clock + .market-clock::before {
        display: none;
    }
}

/* ── Hide hero illustration on tablet/mobile ─────────────────── */
@media (max-width: 960px) {
    .hero-illustration { display: none; }
}

/* ── Nav: thin gold accent bottom border ────────────────────── */
.nav {
    border-bottom: 1px solid var(--gold-border) !important;
}
.nav.scrolled {
    background: rgba(6,11,20,0.96) !important;
    backdrop-filter: blur(28px) !important;
    -webkit-backdrop-filter: blur(28px) !important;
    border-bottom-color: var(--gold-border) !important;
    box-shadow: 0 1px 0 var(--gold-border),
                0 8px 32px rgba(0,0,0,0.5) !important;
}

/* ── Nav links: gold hover underline ────────────────────────── */
.nav-links a {
    position: relative;
}
.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px; left: 0;
    width: 0; height: 1px;
    background: var(--gold-grad);
    transition: width 0.3s ease;
}
.nav-links a:hover::after,
.nav-links a.active::after { width: 100%; }

/* ── Cursor glow: switch to gold ────────────────────────────── */
.cursor-glow {
    background: radial-gradient(circle, rgba(200,169,106,0.06) 0%, transparent 65%) !important;
}

/* ── Footer link underline: gold ────────────────────────────── */
.footer-col ul a::after {
    background: var(--gold) !important;
}

/* ── Card shimmer: gold tint ────────────────────────────────── */
.glass-card .shimmer-line {
    background: linear-gradient(105deg,
        transparent 40%,
        rgba(200,169,106,0.07) 50%,
        transparent 60%) !important;
}

/* ── Stock ticker: gold separators ──────────────────────────── */
.ticker-item .sep {
    color: var(--gold) !important;
    opacity: 0.55;
}

/* ── Hero badge dot: gold pulse ─────────────────────────────── */
.hero-badge .dot {
    background: var(--gold) !important;
    box-shadow: 0 0 0 0 rgba(200,169,106,0.4) !important;
    animation: goldDotPulse 2s ease-in-out infinite !important;
}
@keyframes goldDotPulse {
    0%   { box-shadow: 0 0 0 0 rgba(200,169,106,0.5); }
    70%  { box-shadow: 0 0 0 8px rgba(200,169,106,0); }
    100% { box-shadow: 0 0 0 0 rgba(200,169,106,0); }
}

/* ── Hero badge border: gold ────────────────────────────────── */
.hero-badge {
    border-color: var(--gold-border) !important;
    color: rgba(200,169,106,0.85) !important;
}

/* ── Section title gradient: keep blue for body, gold only on hero/page-header ── */
/* (already handled above; no extra override needed) */
