/* ─────────────────────────────────────────────────────────────────────────
   MONKEYBAR COMMON STYLES
   Shared across all pages
───────────────────────────────────────────────────────────────────────── */

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

/* ── TOKENS ── */
:root {
  --bg:       #07071A;
  --bg2:      #0B0B22;
  --bg3:      #0F0F2E;
  --p:        #7C3AED;
  --p-lo:     #5B27B8;
  --p-hi:     #A78BFA;
  --p-xs:     rgba(124,58,237,0.10);
  --p-sm:     rgba(124,58,237,0.18);
  --white:    #F5F3FF;
  --grey:     #8B89AB;
  --dim:      #787791;
  --line:     rgba(255,255,255,0.07);
  --f:        'Plus Jakarta Sans', sans-serif;
  --w:        1160px;
  --px:       clamp(1.25rem, 5vw, 3.5rem);
}

body {
  background: var(--bg);
  color: var(--white);
  font-family: var(--f);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.wrap { max-width: var(--w); margin: 0 auto; padding: 0 var(--px); }

/* ── NAV ── */
nav {
  position: fixed;
  inset: 0 0 auto;
  z-index: 200;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--px);
  transition: background 0.3s, border-color 0.3s;
  border-bottom: 1px solid transparent;
}
nav.stuck {
  background: rgba(7,7,26,0.9);
  backdrop-filter: blur(18px);
  border-color: var(--line);
}
.logo { font-size: 1.1rem; font-weight: 800; letter-spacing: -0.02em; color: var(--white); text-decoration: none; display: flex; align-items: center; }
.logo span { color: var(--p-hi); }
.nav-links { display: flex; gap: 2rem; list-style: none; align-items: center; }
.nav-links a { font-size: 0.88rem; font-weight: 500; color: var(--grey); text-decoration: none; transition: color 0.2s; line-height: 1; }
.nav-links a:hover { color: var(--white); }
.nav-links a.active { color: var(--white); }
.nav-btn { font-size: 0.85rem; font-weight: 600; color: #fff; background: var(--p); padding: 0.58rem 1.25rem; border-radius: 6px; text-decoration: none; transition: background 0.2s; line-height: 1; display: flex; align-items: center; }
.nav-btn:hover { background: var(--p-lo); }
.nav-right { display: flex; align-items: center; gap: 1.25rem; }
.nav-tag { font-size: 0.68rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); }
/* ── HAMBURGER ── */
.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  flex-shrink: 0;
}
.nav-hamburger span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--white);
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s, width 0.25s;
  transform-origin: center;
}
.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; width: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── MOBILE DRAWER ── */
.nav-drawer {
  display: none;
  position: fixed;
  top: 68px;
  left: 0; right: 0;
  background: rgba(7,7,26,0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line);
  z-index: 199;
  padding: 1.5rem var(--px) 2rem;
  flex-direction: column;
  gap: 0;
}
.nav-drawer.open { display: flex; }
.nav-drawer ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 1.25rem;
}
.nav-drawer ul li a {
  display: block;
  padding: 0.85rem 0;
  font-size: 1rem;
  font-weight: 500;
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  transition: color 0.2s;
}
.nav-drawer ul li:first-child a { border-top: 1px solid var(--line); }
.nav-drawer ul li a:hover, .nav-drawer ul li a.active { color: var(--white); }
.nav-drawer .nav-btn {
  width: 100%;
  text-align: center;
  justify-content: center;
  padding: 0.85rem;
  font-size: 0.95rem;
}

@media (max-width: 680px) {
  .nav-links { display: none; }
  .nav-hamburger { display: flex; }
  .nav-btn { display: none; }
  .lang-toggle { font-size: 0.82rem; padding: 4px 10px; }
}

/* ── BTN ── */
.btn { display: inline-block; font-family: var(--f); font-size: 0.88rem; font-weight: 600; text-decoration: none; border-radius: 6px; padding: 0.8rem 1.6rem; text-align: center; white-space: nowrap; transition: all 0.2s; }
.btn-solid { background: var(--p); color: #fff; }
.btn-solid:hover { background: var(--p-lo); transform: translateY(-1px); }
.btn-soft { background: rgba(255,255,255,0.06); color: var(--grey); border: 1px solid var(--line); }
.btn-soft:hover { color: var(--white); background: rgba(255,255,255,0.1); }
.btn-ghost { font-size: 0.85rem; font-weight: 500; color: var(--grey); text-decoration: none; display: inline-flex; align-items: center; gap: 0.4rem; transition: color 0.2s; }
.btn-ghost:hover { color: var(--white); }

/* ── REVEAL ── */
.r { opacity: 0; transform: translateY(12px); transition: opacity 0.6s ease, transform 0.6s ease; }
.r.in { opacity: 1; transform: none; }
.r.d1 { transition-delay: 0.1s; }
.r.d2 { transition-delay: 0.2s; }
.r.d3 { transition-delay: 0.3s; }
.r.s1 { transition-delay: 0.08s; }
.r.s2 { transition-delay: 0.16s; }
.r.s3 { transition-delay: 0.24s; }
.r.s4 { transition-delay: 0.32s; }

@keyframes up {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

/* ── TEXT EMPHASIS ── */
.hl {
  display: inline;
  background: rgba(124,58,237,0.18);
  border: 1px solid rgba(167,139,250,0.25);
  border-radius: 5px;
  padding: 0.08em 0.38em;
  color: var(--p-hi);
  font-style: normal;
  white-space: nowrap;
}

.grad {
  color: var(--p-hi);
  font-style: normal;
}

.wave {
  position: relative;
  display: inline;
  font-style: normal;
}
.wave::after {
  content: '';
  position: absolute;
  left: 0; right: 0;
  bottom: -5px;
  height: 7px;
  background-image: url("data:image/svg+xml,%3Csvg width='120' height='7' viewBox='0 0 120 7' preserveAspectRatio='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 3.5 Q15 0.5 30 3.5 Q45 6.5 60 3.5 Q75 0.5 90 3.5 Q105 6.5 120 3.5' stroke='%23a78bfa' stroke-width='1.8' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: repeat-x;
  background-size: 80px 100%;
  opacity: 0.85;
}

.cross {
  position: relative;
  color: var(--grey);
}
.cross::after {
  content: '';
  position: absolute;
  left: 0; right: 0;
  top: 50%;
  height: 1.5px;
  background: var(--dim);
  border-radius: 2px;
}

/* ── FLOAT ANIMATIONS ── */
@keyframes chip-float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25%       { transform: translateY(-14px) rotate(2deg); }
  50%       { transform: translateY(-6px) rotate(-1deg); }
  75%       { transform: translateY(-18px) rotate(1.5deg); }
}

@keyframes ring-float {
  0%, 100% { transform: translateY(0) scale(1); }
  40%       { transform: translateY(-20px) scale(1.04); }
  70%       { transform: translateY(-8px) scale(0.97); }
}

@keyframes ring-spin {
  0%   { transform: rotate(0deg) translateY(0); }
  50%  { transform: rotate(180deg) translateY(-12px); }
  100% { transform: rotate(360deg) translateY(0); }
}

@keyframes blob-drift {
  0%   { opacity: 1; transform: scale(1) translate(0, 0); }
  33%  { transform: scale(1.08) translate(-2%, 2%); }
  66%  { transform: scale(0.96) translate(3%, -1%); }
  100% { opacity: 0.85; transform: scale(1.04) translate(-1%, 3%); }
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.5; transform: scale(0.8); }
}

@keyframes bar-grow {
  from { width: 0; }
  to   { width: var(--w, 80%); }
}

/* ── FLOAT ELEMENTS ── */
.float-chip {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.73rem;
  font-weight: 600;
  color: var(--p-hi);
  background: rgba(124,58,237,0.12);
  border: 1px solid rgba(167,139,250,0.22);
  border-radius: 100px;
  padding: 0.4rem 0.85rem;
  white-space: nowrap;
  backdrop-filter: blur(8px);
  pointer-events: none;
  user-select: none;
  animation: chip-float var(--dur, 8s) ease-in-out infinite;
  animation-delay: var(--del, 0s);
  z-index: 1;
}
.float-chip .dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--p-hi);
  flex-shrink: 0;
}

.float-ring {
  position: absolute;
  border-radius: 50%;
  border: 1.5px solid rgba(167,139,250,0.2);
  pointer-events: none;
  user-select: none;
  animation: ring-float var(--dur, 10s) ease-in-out infinite;
  animation-delay: var(--del, 0s);
  z-index: 1;
}
.float-ring.inner {
  border: 1.5px solid rgba(124,58,237,0.15);
  animation-name: ring-spin;
}
.float-ring.spin {
  border-color: rgba(124,58,237,0.14);
  animation-name: ring-spin;
  animation-timing-function: linear;
}

.float-dots {
  position: absolute;
  pointer-events: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  animation: chip-float var(--dur, 12s) ease-in-out infinite;
  animation-delay: var(--del, 0s);
  z-index: 1;
}
.float-dots span {
  width: 3px; height: 3px;
  border-radius: 50%;
  background: rgba(167,139,250,0.35);
  display: block;
}

@media (max-width: 900px) {
  .float-chip, .float-ring, .float-dots { display: none; }
}

/* ── FLOAT MOCKUPS ── */
.float-mockup {
  position: absolute;
  pointer-events: none;
  user-select: none;
  border-radius: 12px;
  background: rgba(15, 15, 38, 0.85);
  border: 1px solid rgba(167,139,250,0.2);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 1rem;
  font-size: 0.72rem;
  font-family: var(--f);
  z-index: 2;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 0 1px rgba(167,139,250,0.08);
  animation: chip-float var(--dur, 10s) ease-in-out infinite;
  animation-delay: var(--del, 0s);
  width: 200px;
}
.fm-title {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--p-hi);
  margin-bottom: 0.65rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.fm-title::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--p-hi);
  flex-shrink: 0;
}
.fm-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.3rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  color: var(--grey);
  font-size: 0.7rem;
  font-weight: 300;
}
.fm-row:last-child { border-bottom: none; }
.fm-row span { font-weight: 600; color: var(--white); }
.fm-badge {
  font-size: 0.6rem;
  font-weight: 600;
  padding: 0.15rem 0.45rem;
  border-radius: 100px;
  white-space: nowrap;
}
.fm-badge.red    { background: rgba(239,68,68,0.15);  color: #EF4444; }
.fm-badge.green  { background: rgba(52,211,153,0.15); color: #34D399; }
.fm-badge.yellow { background: rgba(251,191,36,0.15);  color: #FBBF24; }
.fm-badge.purple { background: rgba(167,139,250,0.15); color: var(--p-hi); }
.fm-bars {
  display: flex;
  align-items: flex-end;
  gap: 4px;
  height: 36px;
  margin-top: 0.6rem;
}
.fm-bar {
  flex: 1;
  border-radius: 3px 3px 0 0;
  background: rgba(124,58,237,0.3);
  transition: height 0.3s;
}
.fm-bar.hi { background: var(--p-hi); }
.fm-metric { margin-top: 0.4rem; }
.fm-num {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--white);
  letter-spacing: -0.04em;
  line-height: 1.1;
}
.fm-sub {
  font-size: 0.65rem;
  color: var(--grey);
  margin-top: 0.2rem;
}
.fm-trend {
  font-size: 0.68rem;
  font-weight: 600;
  color: #34D399;
  margin-top: 0.3rem;
}

@media (max-width: 1100px) { .float-mockup { display: none; } }

/* ── PHASE ICON CARDS ── */
.phase-icon-cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.85rem;
  padding: 0.25rem 0 3rem;
}

.pic {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 1.2rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  transition: border-color 0.2s, background 0.2s;
}
.pic:hover { border-color: rgba(167,139,250,0.3); background: rgba(124,58,237,0.05); }

.pic-icon {
  width: 2.2rem; height: 2.2rem;
  border-radius: 8px;
  background: var(--p-xs);
  border: 1px solid rgba(167,139,250,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.pic-icon svg {
  width: 1rem; height: 1rem;
  stroke: var(--p-hi);
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.pic-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1.2;
}
.pic-desc {
  font-size: 0.75rem;
  color: var(--grey);
  font-weight: 300;
  line-height: 1.55;
}

@media (max-width: 900px) { .phase-icon-cards { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 500px) { .phase-icon-cards { grid-template-columns: 1fr 1fr; } }

/* ── FOOTER ── */
footer {
  background: var(--bg2);
  border-top: 1px solid var(--line);
  padding: clamp(3rem, 6vw, 5rem) 0 2.5rem;
}

.foot-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--line);
  margin-bottom: 2rem;
}

.foot-logo { font-size: 1rem; font-weight: 800; letter-spacing: -0.02em; margin-bottom: 0.65rem; }
.foot-logo span { color: var(--p-hi); }
.foot-tag { font-size: 0.82rem; color: var(--grey); font-weight: 300; line-height: 1.65; max-width: 28ch; margin-bottom: 1.1rem; }
.foot-geo { font-size: 0.68rem; color: var(--dim); letter-spacing: 0.1em; text-transform: uppercase; }
.foot-col-title { font-size: 0.62rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--white); margin-bottom: 1rem; }
.foot-links { list-style: none; display: flex; flex-direction: column; gap: 0.6rem; }
.foot-links a { font-size: 0.82rem; color: var(--grey); text-decoration: none; font-weight: 300; transition: color 0.2s; }
.foot-links a:hover { color: var(--white); }
.foot-bottom { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }
.foot-copy { font-size: 0.73rem; color: var(--dim); }
.foot-email a { font-size: 0.78rem; color: var(--p-hi); text-decoration: none; }
.foot-email a:hover { text-decoration: underline; }

@media (max-width: 820px) { .foot-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .foot-grid { grid-template-columns: 1fr; } }

/* ── CANVAS ── */
canvas[aria-hidden="true"] {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  opacity: 0.55;
  z-index: 0;
}
