/* ═══════════════════════════════════════════════════════
  DECIMES ASSET & WEALTH — Three.js Scroll Zoom Journey
   Palette: Obsidian · Cyan · Gold
   ═══════════════════════════════════════════════════════ */

/* ── RESET ──────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  background: #000810;
  font-family: 'Inter', system-ui, sans-serif;
  font-weight: 300;
  color: #fff;
  overflow-x: hidden;
}

/* ── DESIGN TOKENS ──────────────────────────────────── */
:root {
  --bg:      #000810;
  --navy:    #000d1a;
  --cyan:    #00a8e8;
  --bright:  #00d4ff;
  --gold:    #c9a84c;
  --white:   #ffffff;
  --dim:     rgba(255,255,255,.58);
  --glass:   rgba(0, 12, 28, .78);
  --border:  rgba(0, 168, 232, .22);
  --serif:   'Cormorant Garamond', Georgia, serif;
  --sans:    'Inter', system-ui, sans-serif;
  --ease:    cubic-bezier(.16, 1, .3, 1);
}

/* ── SCENE (sticky viewport) ────────────────────────── */
#scene {
  position: sticky;
  top: 0;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  background: var(--bg);
  z-index: 1;
}

/* ── TREE STAGE ─────────────────────────────────────── */
#tree-stage {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

#three-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  will-change: transform;
}

#tree-stage::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse at 50% 52%, transparent 24%, rgba(0, 8, 16, .2) 72%, rgba(0, 8, 16, .72) 100%);
  z-index: 2;
}

/* ── OVERLAYS ────────────────────────────────────────── */
.vig-top {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 180px;
  background: linear-gradient(to bottom, rgba(0,8,16,.85) 0%, transparent 100%);
  pointer-events: none;
  z-index: 4;
}
.vig-bottom {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 200px;
  background: linear-gradient(to top, rgba(0,8,16,.92) 0%, transparent 100%);
  pointer-events: none;
  z-index: 4;
}
.vig-sides {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to right, rgba(0,8,16,.7) 0%, transparent 22%, transparent 78%, rgba(0,8,16,.7) 100%);
  pointer-events: none;
  z-index: 4;
}

/* Subtle scan lines for fintech atmosphere */
.scanlines {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background-image: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 3px,
    rgba(0, 168, 232, .018) 3px,
    rgba(0, 168, 232, .018) 4px
  );
  opacity: .6;
}

/* ── PANELS ──────────────────────────────────────────── */
.panel {
  position: absolute;
  inset: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity .08s linear; /* JS controls this mostly */
}

/* Give active panels pointer events */
.panel.visible { pointer-events: auto; }

.panel-body {
  pointer-events: auto;
}

/* ── GLASS CARD ─────────────────────────────────────── */
.glass-card {
  padding: 44px 48px;
  background: var(--glass);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  border: 1px solid var(--border);
  border-radius: 3px;
  max-width: 460px;
  position: relative;
  overflow: hidden;
}

/* Top accent line on glass cards */
.glass-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--cyan), var(--bright), transparent);
  opacity: .6;
}

.side-left  { margin-left: 60px; }
.side-right { margin-left: auto; margin-right: 60px; }

.centered-card {
  margin: 0 auto;
  text-align: center;
  max-width: 520px;
}

/* ── HERO PANEL ─────────────────────────────────────── */
#panel-0 {
  align-items: flex-start;
  padding: 0 64px;
  padding-top: 160px;
}

.hero-body {
  max-width: 700px;
}

.eyebrow {
  display: block;
  font-size: .62rem;
  letter-spacing: .38em;
  color: var(--cyan);
  text-transform: uppercase;
  margin-bottom: 28px;
}

h1 {
  font-family: var(--serif);
  font-size: clamp(4rem, 8vw, 7.5rem);
  font-weight: 300;
  line-height: .9;
  letter-spacing: -.01em;
  margin-bottom: 30px;
}
h1 span { display: block; color: #fff; }
h1 em   { display: block; font-style: italic; color: var(--bright); }

.hero-sub {
  font-size: .88rem;
  color: var(--dim);
  margin-bottom: 28px;
  letter-spacing: .04em;
}

.services-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}
.services-row span {
  padding: 4px 14px;
  border: 1px solid var(--border);
  border-radius: 2px;
  font-size: .64rem;
  letter-spacing: .1em;
  color: var(--cyan);
  background: rgba(0,168,232,.04);
}

/* Scroll cue */
.scroll-cue {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  opacity: .92;
}
.cue-bar {
  width: 180px;
  height: 2px;
  background: rgba(255,255,255,.1);
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
}
.cue-inner {
  position: absolute;
  top: 0;
  left: -42%;
  width: 42%;
  height: 100%;
  background: linear-gradient(to bottom, transparent, var(--bright));
  box-shadow: 0 0 12px var(--bright);
  animation: sweep 1.9s ease-in-out infinite;
}
.scroll-cue p {
  font-size: .66rem;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: rgba(255,255,255,.7);
  writing-mode: horizontal-tb;
}
@keyframes sweep { 0%{left:-42%} 100%{left:105%} }

/* ── SECTION TYPOGRAPHY ──────────────────────────────── */
.s-num {
  display: block;
  font-size: .58rem;
  letter-spacing: .34em;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 14px;
}

h2 {
  font-family: var(--serif);
  font-size: clamp(1.9rem, 3vw, 2.8rem);
  font-weight: 300;
  line-height: 1.1;
  margin-bottom: 18px;
  color: #fff;
}

.rule {
  width: 40px;
  height: 1px;
  background: linear-gradient(to right, var(--gold), transparent);
  margin-bottom: 18px;
}

.glass-card p {
  font-size: .88rem;
  line-height: 1.88;
  color: var(--dim);
  margin-bottom: 22px;
}
.glass-card p:last-child { margin-bottom: 0; }

/* Tags */
.tags {
  list-style: none;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.tags li {
  padding: 4px 12px;
  border: 1px solid var(--border);
  border-radius: 2px;
  font-size: .64rem;
  letter-spacing: .1em;
  color: var(--cyan);
}

/* ── STRATEGY LIST ───────────────────────────────────── */
.strategy-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.strat {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(0,168,232,.1);
}
.strat:last-child { border-bottom: none; padding-bottom: 0; }

.strat-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--bright);
  box-shadow: 0 0 8px var(--bright);
  flex-shrink: 0;
  margin-top: 7px;
}
.strat strong {
  display: block;
  font-size: .88rem;
  font-weight: 500;
  color: #fff;
  margin-bottom: 4px;
}
.strat span {
  display: block;
  font-size: .76rem;
  color: rgba(255,255,255,.45);
  line-height: 1.5;
}

/* ── VISION CARD ─────────────────────────────────────── */
blockquote {
  font-family: var(--serif);
  font-size: clamp(1.7rem, 3vw, 2.5rem);
  font-weight: 300;
  font-style: italic;
  line-height: 1.35;
  color: #fff;
  margin-bottom: 22px;
  border: none;
}

.vision-sub {
  font-size: .88rem;
  line-height: 1.8;
  color: var(--dim);
  margin-bottom: 32px;
}

.cta {
  display: inline-block;
  padding: 12px 32px;
  background: linear-gradient(135deg, var(--cyan), var(--bright));
  color: var(--bg);
  text-decoration: none;
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .15em;
  text-transform: uppercase;
  border-radius: 2px;
  transition: opacity .2s, transform .2s, box-shadow .2s;
}
.cta:hover {
  opacity: .85;
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(0,212,255,.3);
}

/* ── HEADER ──────────────────────────────────────────── */
#site-header {
  position: absolute;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 44px;
  background: linear-gradient(to bottom, rgba(0,8,16,.8), transparent);
}

.logo { display: flex; flex-direction: column; gap: 3px; }
.logo-name {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: .22em;
}
.logo-tag {
  font-size: .46rem;
  letter-spacing: .44em;
  color: var(--cyan);
  text-transform: uppercase;
}

/* Stage dots */
.stage-dots { display: flex; gap: 10px; align-items: center; }
.sdot {
  width: 7px; height: 7px;
  border-radius: 50%;
  border: 1px solid rgba(0,168,232,.3);
  background: transparent;
  cursor: pointer;
  padding: 0;
  transition: all .35s var(--ease);
}
.sdot.active {
  background: var(--bright);
  border-color: var(--bright);
  box-shadow: 0 0 10px var(--bright);
  transform: scale(1.35);
}

/* ── PROGRESS BAR ────────────────────────────────────── */
#pbar-wrap {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: rgba(255,255,255,.05);
  z-index: 60;
}
#pbar {
  height: 100%;
  width: 0%;
  background: linear-gradient(to right, var(--cyan), var(--bright));
  box-shadow: 0 0 10px var(--bright);
  transition: width .06s linear;
}

/* ── STAGE LABEL (bottom left) ───────────────────────── */
#stage-label {
  position: absolute;
  bottom: 24px;
  left: 44px;
  z-index: 50;
  display: flex;
  flex-direction: column;
  gap: 4px;
  opacity: 0;
  transition: opacity .5s;
}
#stage-label.show { opacity: 1; }
#sl-num {
  font-size: .58rem;
  letter-spacing: .3em;
  color: var(--gold);
  text-transform: uppercase;
}
#sl-title {
  font-family: var(--serif);
  font-style: italic;
  font-size: .76rem;
  color: rgba(255,255,255,.4);
}

/* ── ZOOM RING (subtle pulse around zoomed area) ─────── */
#zoom-ring {
  position: absolute;
  inset: 0;
  z-index: 6;
  pointer-events: none;
  box-shadow: inset 0 0 0 0 rgba(0,212,255,0);
  transition: box-shadow 1.2s var(--ease);
}
#zoom-ring.zoomed {
  box-shadow: inset 0 0 80px -20px rgba(0,168,232,.12);
}

/* ── SCROLL SPACER ───────────────────────────────────── */
#spacer {
  /* 7 × 100vh — controls total journey scroll distance */
  height: 700vh;
}

/* ── FOOTER ──────────────────────────────────────────── */
#site-footer {
  background: var(--navy);
  border-top: 1px solid var(--border);
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 36px 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}
.footer-brand {
  font-family: var(--serif);
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .24em;
}
.footer-motto {
  font-family: var(--serif);
  font-style: italic;
  color: var(--cyan);
  font-size: .88rem;
}
.footer-legal {
  font-size: .6rem;
  color: rgba(255,255,255,.22);
  letter-spacing: .05em;
}
.footer-legal a {
  color: rgba(255,255,255,.35);
  text-decoration: none;
  transition: color .2s;
}
.footer-legal a:hover { color: var(--cyan); }

/* ── RESPONSIVE ──────────────────────────────────────── */
@media (max-width: 768px) {
  h1 { font-size: 3rem; }
  h2 { font-size: 1.8rem; }
  blockquote { font-size: 1.6rem; }

  #panel-0 { padding: 0 24px; padding-top: 130px; }

  .cue-bar { width: 140px; }

  .glass-card { max-width: 88vw; padding: 28px 24px; }
  .side-left  { margin-left: 24px; }
  .side-right { margin-right: 24px; }

  #site-header { padding: 18px 24px; }
  #stage-label { left: 24px; }
}

/* ── REDUCED MOTION ──────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .cue-inner { animation: none; }
  #three-canvas { transition: none !important; }
  #tree-stage::after { background: rgba(0, 8, 16, .12); }
}