/* ═══════════════════════════════════════════════════
   بُ۲رو — Landing Page  |  All assets served locally
   ═══════════════════════════════════════════════════ */

/* ── Local Fonts ──────────────────────────────────── */
@font-face {
  font-family: 'Vazirmatn';
  src: url('../fonts/Vazirmatn-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Vazirmatn';
  src: url('../fonts/Vazirmatn-Bold.woff2') format('woff2');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Vazirmatn';
  src: url('../fonts/Vazirmatn-Black.woff2') format('woff2');
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'IRANSans';
  src: url('../fonts/IRANSansWeb.woff2') format('woff2'),
       url('../fonts/IRANSans-web.woff') format('woff');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

/* ── Reset & Base ─────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* ── Core palette ──────────────────────────────── */
  --primary:       #00ff9d;          /* نئون سبز — اصلی */
  --primary-d:     #00c97a;          /* تیره‌تر برای hover */
  --primary-l:     rgba(0,255,157,.10);
  --accent:        #3d9eff;          /* آبی برقی */
  --accent-l:      rgba(61,158,255,.10);
  --hot:           #ff3cac;          /* مجنتا — تاکید */
  --purple:        #9d4eff;          /* بنفش الکتریک */
  --green:         #00ff9d;
  --yellow:        #ffe066;
  /* ── Neutrals ──────────────────────────────────── */
  --dark:          #050505;
  --dark-2:        #0a0a0a;
  --dark-3:        #111111;
  --text:          #e8e8e8;
  --muted:         #666;
  --border:        rgba(255,255,255,.07);
  --card:          rgba(255,255,255,.03);
  --radius:        6px;
  --radius-xl:     12px;
  --shadow-lg:     0 24px 70px rgba(0,0,0,.8);
  --font:          'Vazirmatn', 'IRANSans', system-ui, sans-serif;
  --transition:    .18s cubic-bezier(.4,0,.2,1);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--dark);
  color: var(--text);
  line-height: 1.75;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ── Utilities ────────────────────────────────────── */
.container { max-width: 1120px; margin: 0 auto; padding: 0 1.5rem; }

.gradient-text {
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 60%, var(--hot) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── Buttons ──────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: .45rem;
  font-family: var(--font); font-weight: 700; cursor: pointer;
  border: none; text-decoration: none;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition);
  border-radius: 999px; white-space: nowrap; user-select: none;
}
.btn--sm  { padding: .45rem 1.2rem; font-size: .82rem; }
.btn--lg  { padding: .9rem 2rem;    font-size: 1rem;   }

.btn--primary {
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
  color: #050505;
  box-shadow: 0 4px 24px rgba(0,255,157,.3), 0 0 60px rgba(61,158,255,.15);
}
.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 36px rgba(0,255,157,.45), 0 0 80px rgba(61,158,255,.2);
}
.btn--ghost {
  color: var(--muted); background: transparent;
}
.btn--ghost:hover { color: var(--text); }

/* ── Badge / Tag ──────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; gap: .4rem;
  background: rgba(0,255,157,.08); color: var(--primary);
  border: 1px solid rgba(0,255,157,.25);
  padding: .35rem .95rem; border-radius: 999px;
  font-size: .78rem; font-weight: 700; margin-bottom: 1.4rem;
  box-shadow: 0 0 20px rgba(0,255,157,.15), 0 0 50px rgba(0,255,157,.05);
}

.section-tag {
  display: inline-block;
  background: rgba(61,158,255,.1); color: var(--accent);
  border: 1px solid rgba(61,158,255,.22);
  font-size: .75rem; font-weight: 700;
  padding: .25rem .8rem; border-radius: 999px;
  margin-bottom: .6rem; letter-spacing: .02em;
}

/* ── Section header ───────────────────────────────── */
.section-header { text-align: center; margin-bottom: 3.5rem; }
.section-title   { font-size: clamp(1.65rem, 3vw, 2.3rem); font-weight: 900; margin-bottom: .55rem; }
.section-desc    { color: var(--muted); font-size: .97rem; max-width: 520px; margin: 0 auto; }

/* ══════════════════════════════════════════════════
   NAV
══════════════════════════════════════════════════ */
.nav {
  position: fixed; top: 0; inset-inline: 0; z-index: 200;
  transition: background var(--transition), border-color var(--transition);
}
.nav.scrolled {
  background: rgba(14,13,8,.92);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}
.nav__inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 68px;
}
.nav__logo {
  display: flex; align-items: center; gap: .55rem;
  font-size: 1.3rem; font-weight: 900; text-decoration: none;
  color: var(--text);
}
.logo-icon { font-size: 1.8rem; color: var(--primary); }
.logo-text {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.nav__links {
  display: flex; align-items: center; gap: 2rem;
}
.nav__links a:not(.btn) {
  color: var(--muted); text-decoration: none; font-size: .9rem; font-weight: 600;
  transition: color var(--transition);
}
.nav__links a:not(.btn):hover { color: var(--text); }

/* ══════════════════════════════════════════════════
   HERO
══════════════════════════════════════════════════ */
.hero {
  position: relative; overflow: hidden;
  min-height: 100vh; display: flex; align-items: center;
  padding: 10rem 0 7rem;
}

.hero__bg { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.hero__blob {
  position: absolute; border-radius: 50%; filter: blur(90px); opacity: .16;
}
.hero__blob--1 {
  width: 700px; height: 700px;
  background: radial-gradient(circle, var(--primary), transparent 70%);
  top: -250px; right: -200px;
}
.hero__blob--2 {
  width: 500px; height: 500px;
  background: radial-gradient(circle, var(--hot), transparent 70%);
  bottom: -150px; left: -150px;
}

/* blob سوم -- بنفش وسط */
.hero__blob--3 {
  position: absolute; border-radius: 50%; filter: blur(90px); opacity: .12;
  width: 400px; height: 400px;
  background: radial-gradient(circle, var(--purple), transparent 70%);
  top: 30%; left: 40%;
}
.hero__grid {
  position: absolute; inset: 0; overflow: hidden;
}

/* ۴ مربع متحرک با گرادیانت نرم */
.hero__grid::before,
.hero__grid::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  animation: gridDrift 14s ease-in-out infinite alternate;
}
.hero__grid::before {
  width: 380px; height: 380px;
  background: radial-gradient(circle, rgba(0,255,157,.06), rgba(61,158,255,.04) 50%, transparent 70%);
  top: 10%; right: 15%;
  animation-duration: 16s;
}
.hero__grid::after {
  width: 280px; height: 280px;
  background: radial-gradient(circle, rgba(255,60,172,.05), transparent 70%);
  bottom: 20%; left: 20%;
  animation-duration: 11s;
  animation-direction: alternate-reverse;
}

/* خطوط شبکه */
.hero__grid-lines {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(0,255,157,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(61,158,255,.025) 1px, transparent 1px);
  background-size: 60px 60px;
  animation: gridSlide 20s linear infinite;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
}

@keyframes gridDrift {
  0%   { transform: translate(0, 0) scale(1); }
  33%  { transform: translate(30px, -20px) scale(1.08); }
  66%  { transform: translate(-20px, 15px) scale(.96); }
  100% { transform: translate(15px, 25px) scale(1.04); }
}
@keyframes gridSlide {
  0%   { background-position: 0 0; }
  100% { background-position: 60px 60px; }
}

.hero__inner {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 5rem; align-items: center;
}

.hero__title {
  font-size: clamp(2.1rem, 4.5vw, 3.4rem);
  font-weight: 900; line-height: 1.25;
  margin-bottom: 1.3rem;
}
.hero__desc {
  color: var(--muted); font-size: 1.05rem;
  max-width: 460px; margin-bottom: 2.2rem; line-height: 1.85;
}
.hero__actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-bottom: 2.8rem; }

.hero__stats {
  display: inline-flex; align-items: center; gap: 1.6rem;
  padding: 1rem 1.6rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.stat { text-align: center; }
.stat__num   { display: block; font-size: 1.5rem; font-weight: 900; color: var(--primary); line-height: 1; }
.stat__label { font-size: .72rem; color: var(--muted); margin-top: .2rem; display: block; }
.stat__divider { width: 1px; height: 38px; background: var(--border); }

/* ── Math Solver Widget (inside phone) ────────── */
.phone-wrap {
  position: relative; z-index: 2;
  display: flex; justify-content: center;
}

.math-solver {
  width: 100%; height: 100%;
  background: var(--dark);
  display: flex; flex-direction: column;
  overflow: hidden;
  border-radius: 2.4rem;
}
/* ── Game Status Bar ─────────────────────────── */
.game-bar {
  display: flex; align-items: center;
  padding: .45rem .9rem .3rem;
  gap: .3rem;
  background: var(--dark);
  border-bottom: 1px solid rgba(0,255,157,.08);
  position: relative; z-index: 2;
}
.game-bar__left  { display: flex; gap: .18rem; align-items: center; }
.game-bar__center{ flex: 1; text-align: center; }
.game-bar__right { display: flex; align-items: center; gap: .22rem; }

.game-life {
  font-size: .95rem; color: var(--hot);
  transition: transform .2s, color .3s, text-shadow .3s;
  text-shadow: 0 0 8px rgba(255,60,172,.5);
}
.game-life.lost {
  color: #1a0d14 !important;
  text-shadow: none !important;
}
.game-life.pulse {
  animation: lifePulse .35s ease;
}
@keyframes lifePulse {
  0%  { transform: scale(1);   }
  40% { transform: scale(1.5); }
  100%{ transform: scale(1);   }
}

.game-level {
  font-size: .62rem; color: #555; font-weight: 700; letter-spacing: .05em;
}
#levelNum { color: var(--primary); }

.game-star { font-size: .75rem; color: var(--accent); }
.game-score {
  font-size: .78rem; font-weight: 900; color: var(--primary);
  text-shadow: 0 0 10px rgba(0,255,157,.5);
  min-width: 2ch;
  transition: transform .2s;
}
.game-score.bump { animation: scoreBump .3s ease; }
@keyframes scoreBump {
  0%  { transform: scale(1); }
  50% { transform: scale(1.4) translateY(-2px); }
  100%{ transform: scale(1); }
}

/* ── XP bar ─────────────────────────────────── */
.game-xp {
  height: 2px; background: #111; position: relative; z-index: 2;
}
.game-xp__fill {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transition: width .6s cubic-bezier(.22,1,.36,1);
  box-shadow: 0 0 8px rgba(0,255,157,.6);
}

/* ── Combo badge ─────────────────────────────── */
.game-combo {
  position: absolute; top: 52px; left: 50%; transform: translateX(-50%) scale(0);
  z-index: 20;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: var(--dark); font-size: .65rem; font-weight: 900;
  padding: .22rem .65rem; border-radius: 999px;
  white-space: nowrap;
  pointer-events: none;
  transition: transform .25s cubic-bezier(.34,1.56,.64,1), opacity .25s;
  opacity: 0;
  letter-spacing: .04em;
}
.game-combo.show {
  transform: translateX(-50%) scale(1);
  opacity: 1;
}

/* ── Particle canvas ─────────────────────────── */
.game-canvas {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  pointer-events: none; z-index: 10;
}

/* ── Math solver (position relative for canvas) ── */
.math-solver { position: relative; }

/* ── Problem display ─────────────────────────── */
.math-solver__problem {
  padding: 1.1rem .9rem .5rem;
  font-size: 1.55rem; font-weight: 900;
  direction: ltr; text-align: center;
  letter-spacing: .03em;
  min-height: 3.4rem; line-height: 1.5;
  display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: .04rem;
}

/* Tokens — dim by default, lit when .hi */
.p-tok {
  transition: color .3s ease, text-shadow .3s ease, font-size .25s ease;
  color: #3a3630;
}
.p-tok--num {
  color: #2a3a2a;
  font-weight: 800;
  /* Crystal glow base — always on numbers */
  text-shadow:
    0 0 8px rgba(0,255,157,.12),
    0 0 2px rgba(0,255,157,.08);
}
.p-tok--neg {
  color: #3a2a30;
  font-weight: 800;
  text-shadow:
    0 0 8px rgba(255,60,172,.15),
    0 0 2px rgba(255,60,172,.1);
}
.p-tok--op    { color: #2e2b26; font-size: 1.2rem; }
.p-tok--lp,
.p-tok--rp    { color: #3a3020; font-weight: 300; }

/* Resolved tokens (substituted values) */
.p-tok.resolved {
  font-size: 1.65rem;
  font-weight: 900;
  /* color + textShadow set inline by JS */
}

/* Highlighted — color/textShadow injected by JS, just add bg */
.p-tok.hi {
  border-radius: 5px;
  background: rgba(255,255,255,.04);
  padding: 0 .2rem;
}

/* ── Steps ─────────────────────────────────── */
.math-solver__steps {
  padding: .4rem .9rem;
  flex: 1;
  display: flex; flex-direction: column; gap: .32rem;
  overflow: hidden;
  direction: rtl;
}
.step-row {
  display: flex; align-items: flex-start; gap: .5rem;
  padding: .4rem .55rem;
  border-radius: 6px;
  border: 1px solid transparent;
  background: rgba(255,255,255,.018);
  opacity: 0; transform: translateX(10px);
  transition: opacity .3s ease, transform .3s ease;
}
.step-row.show { opacity: 1; transform: none; }
.step-row.done {
  border-color: rgba(0,255,157,.1);
  background: rgba(0,255,157,.03);
}
.step-num {
  width: 20px; height: 20px; min-width: 20px; border-radius: 50%;
  border: 1px solid;
  font-size: .58rem; font-weight: 900;
  display: flex; align-items: center; justify-content: center;
  margin-top: .1rem;
  /* color + border-color injected inline */
}
.step-body {
  display: flex; flex-direction: column; gap: .08rem;
}
.step-label {
  color: #bbb; font-size: .69rem; font-weight: 700; line-height: 1.2;
}
.step-note {
  font-size: .63rem; direction: ltr; text-align: right; line-height: 1.2;
  /* color injected inline */
}
.step-row.done .step-label { color: #666; }

/* ── Result ──────────────────────────────────── */
.math-solver__result {
  margin: .4rem .9rem .55rem;
  padding: .55rem .8rem;
  background: rgba(0,255,157,.07);
  border: 1px solid rgba(0,255,157,.22);
  border-radius: 7px;
  font-size: .9rem; font-weight: 900;
  text-align: center;
  opacity: 0; transition: opacity .45s ease;
  min-height: 2.6rem;
  display: flex; align-items: center; justify-content: center; gap: .5rem;
  direction: rtl;
  box-shadow: 0 0 28px rgba(0,255,157,.1);
}
.math-solver__result.show { opacity: 1; }
.res-icon  { font-size: 1.1rem; color: var(--green); }
.res-label { color: #666; font-size: .74rem; font-weight: 400; }
.res-val   {
  color: var(--primary); font-size: 1.1rem;
  text-shadow:
    0 0 20px rgba(0,255,157,.8),
    0 0 8px  rgba(0,255,157,.5),
    0 0 3px  rgba(0,255,157,.9);
}
.res-pts {
  font-size: .7rem; color: var(--accent); font-weight: 700;
  opacity: .85;
}

/* ── Progress bar ─────────────────────────────── */
.math-solver__bar {
  height: 3px; background: #0a0a0a;
}
.math-solver__bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent), var(--hot));
  width: 0; transition: width .55s ease;
  box-shadow: 0 0 8px rgba(0,255,157,.6);
}

/* ── Phone Mockup ─────────────────────────────── */
.hero__visual {
  position: relative; display: flex;
  justify-content: center; align-items: center;
}

.phone-wrap {
  position: relative; z-index: 2;
}

.phone-mockup {
  position: relative; z-index: 2;
  width: 300px; height: 560px;
  background: var(--dark);
  border-radius: 2.8rem;
  border: 1.5px solid rgba(0,255,157,.2);
  box-shadow:
    0 40px 90px rgba(0,0,0,.9),
    0 0 80px rgba(0,255,157,.12),
    0 0 35px rgba(61,158,255,.08),
    inset 0 1px 0 rgba(0,255,157,.08);
  overflow: hidden;
  padding: .6rem .5rem .6rem;
  display: flex; flex-direction: column;
}
.phone-mockup__notch {
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 70px; height: 16px;
  background: var(--dark);
  border-radius: 0 0 .8rem .8rem;
  z-index: 10;
}
.phone-mockup__screen { flex: 1; display: flex; flex-direction: column; overflow: hidden; border-radius: 2.4rem; }
.phone-mockup__glow {
  position: absolute; inset: -4px; border-radius: 3rem; z-index: -1;
  background: linear-gradient(135deg, var(--primary) 0%, var(--accent) 50%, var(--hot) 100%);
  opacity: .25; filter: blur(22px);
}

.mock-ui { display: flex; flex-direction: column; gap: 1rem; }

.mock-header {
  display: flex; justify-content: space-between; align-items: center;
  font-size: .68rem; color: var(--muted);
  padding-bottom: .75rem; border-bottom: 1px solid var(--border);
}
.mock-level { color: var(--primary); font-weight: 700; }
.mock-lives { display: flex; gap: .1rem; font-size: .9rem; color: var(--accent); }
.mock-lives .mdi { font-size: .9rem; }
.mock-score { color: var(--yellow); font-weight: 700; }

.mock-problem {
  background: rgba(201,162,39,.08);
  border: 1px solid rgba(201,162,39,.18);
  border-radius: .75rem;
  padding: 1rem; text-align: center;
}
.mock-expr {
  font-size: 1.5rem; font-weight: 900; direction: ltr;
  margin-bottom: .4rem;
}
.mock-expr mark {
  background: none; color: var(--primary);
}
.mock-step { font-size: .68rem; color: var(--muted); }

.mock-options { display: flex; flex-direction: column; gap: .55rem; }
.mock-opt {
  padding: .6rem; border-radius: .6rem; text-align: center;
  font-size: .78rem; font-weight: 600; direction: ltr;
  background: var(--card); border: 1px solid var(--border);
}
.mock-opt--selected {
  background: rgba(201,162,39,.15);
  border-color: var(--primary); color: var(--primary);
}

.mock-bar {
  height: 4px; background: rgba(255,255,255,.07); border-radius: 99px; overflow: hidden;
}
.mock-bar__fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 99px;
}

/* ── Floating Cards ───────────────────────────────── */
.floating-card {
  position: absolute;
  background: rgba(20,18,10,.95);
  border: 1px solid rgba(201,162,39,.25);
  backdrop-filter: blur(12px);
  padding: .5rem 1rem;
  border-radius: 6px;
  font-size: .78rem; font-weight: 700;
  animation: float 3.5s ease-in-out infinite;
  box-shadow: 0 8px 24px rgba(0,0,0,.5);
  white-space: nowrap;
  display: flex; align-items: center; gap: .4rem;
  color: var(--primary);
}
.floating-card .mdi { font-size: 1rem; }
.floating-card--1 { top: 12%; left: -30px;  animation-delay: 0s;   color: var(--accent); }
.floating-card--2 { bottom: 30%; right: -20px; animation-delay: 1.2s; color: var(--green); }
.floating-card--3 { bottom: 12%; left: -10px;  animation-delay: 2.2s; color: var(--primary); }

@keyframes float {
  0%,100% { transform: translateY(0px); }
  50%      { transform: translateY(-12px); }
}

/* ══════════════════════════════════════════════════
   FEATURES
══════════════════════════════════════════════════ */
.features {
  padding: 7rem 0;
  background: var(--dark-2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.4rem;
}

.feature-card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 2rem;
  transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
  overflow: hidden;
}
.feature-card::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(0,255,157,.05) 0%, transparent 60%);
  opacity: 0; transition: opacity var(--transition);
}
.feature-card:hover {
  transform: translateY(-5px);
  border-color: rgba(0,255,157,.22);
  box-shadow: 0 16px 40px rgba(0,0,0,.4), 0 0 30px rgba(0,255,157,.07);
}
.feature-card:hover::before { opacity: 1; }

.feature-card__icon {
  font-size: 2.6rem; margin-bottom: 1.1rem; display: block;
  color: var(--primary);
}
.feature-card h3 {
  font-size: 1rem; font-weight: 800; margin-bottom: .55rem;
}
.feature-card p {
  font-size: .86rem; color: var(--muted); line-height: 1.75;
}
.feature-card--highlight {
  background: linear-gradient(135deg, rgba(157,78,255,.08), rgba(61,158,255,.05));
  border-color: rgba(157,78,255,.2);
}
.feature-card__badge {
  position: absolute; top: 1.3rem; left: 1.3rem;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff; font-size: .65rem; font-weight: 800;
  padding: .22rem .7rem; border-radius: 999px;
  letter-spacing: .03em;
}

/* ══════════════════════════════════════════════════
   HOW IT WORKS
══════════════════════════════════════════════════ */
.how { padding: 7rem 0; }

.how__steps {
  display: flex; align-items: flex-start;
  gap: 0; justify-content: center;
}
.how__step {
  flex: 1; text-align: center; max-width: 200px; padding: 0 .5rem;
}
.how__num {
  width: 56px; height: 56px; margin: 0 auto 1.1rem;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #050505; font-weight: 900; font-size: 1.1rem;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 24px rgba(0,255,157,.3), 0 0 40px rgba(61,158,255,.12);
}
.how__step h3 {
  font-size: .95rem; font-weight: 800; margin-bottom: .4rem;
}
.how__step p {
  font-size: .82rem; color: var(--muted); line-height: 1.65;
}
.how__arrow {
  flex: 0 0 auto; align-self: center;
  margin-top: -3.5rem; padding: 0 .5rem;
  color: rgba(61,158,255,.3);
}
.how__arrow-icon { font-size: 2rem; }

/* ══════════════════════════════════════════════════
   MARKET — VS Code style
══════════════════════════════════════════════════ */
.market { padding: 7rem 0; }

/* VS Code window */
.market__box {
  background: var(--dark);
  border: 1px solid #2a2a2a;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 32px 80px rgba(0,0,0,.7), 0 0 0 1px rgba(255,255,255,.04);
}

/* Titlebar */
.vsc-titlebar {
  display: flex; align-items: center;
  background: #161616;
  border-bottom: 1px solid #252525;
  padding: 0 1rem; height: 36px;
  gap: 1rem;
}
.vsc-dots { display: flex; gap: .4rem; }
.vsc-dot {
  width: 12px; height: 12px; border-radius: 50%;
}
.vsc-dot--red    { background: #ff5f57; }
.vsc-dot--yellow { background: #ffbd2e; }
.vsc-dot--green  { background: #28ca41; }

.vsc-title {
  flex: 1; text-align: center;
  font-size: .78rem; color: #888;
  display: flex; align-items: center; justify-content: center; gap: .4rem;
}
.vsc-title .mdi { color: var(--primary); }

.vsc-actions {
  display: flex; gap: .8rem;
  font-size: .85rem; color: #555; cursor: default;
}

/* Body */
.vsc-body {
  display: grid;
  grid-template-columns: 48px 1fr 240px;
  min-height: 420px;
}

/* Sidebar */
.vsc-sidebar {
  background: #111;
  border-left: 1px solid #1e1e1e;
  display: flex; flex-direction: column;
  align-items: center; padding: .8rem 0; gap: .2rem;
}
.vsc-sidebar__item {
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 6px; cursor: pointer;
  color: #555; font-size: 1.3rem;
  transition: color var(--transition), background var(--transition);
  border-right: 2px solid transparent;
}
.vsc-sidebar__item:hover { color: var(--primary); }
.vsc-sidebar__item--active {
  color: var(--primary);
  border-right-color: var(--primary);
  background: rgba(201,162,39,.08);
}

/* Main panel */
.vsc-main {
  padding: 1rem 1.2rem;
  border-left: 1px solid #1e1e1e;
  overflow: hidden;
}

.vsc-search {
  display: flex; align-items: center; gap: .5rem;
  background: var(--dark-3);
  border: 1px solid #2e2e2e;
  border-radius: 5px;
  padding: .5rem .85rem;
  margin-bottom: 1.2rem;
  font-size: .82rem; color: #555;
}
.vsc-search__icon { color: #444; font-size: 1rem; }
.vsc-search__text { flex: 1; }
.vsc-search__cursor {
  width: 1px; height: 14px;
  background: var(--primary);
  animation: blink 1.1s step-end infinite;
}
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0} }

.vsc-cards { display: flex; flex-direction: column; gap: .9rem; }

.vsc-card {
  background: #141414;
  border: 1px solid #252525;
  border-radius: 7px;
  padding: 1rem 1.1rem;
  text-decoration: none; color: var(--text);
  transition: border-color var(--transition), background var(--transition);
  display: block;
}
.vsc-card:hover {
  border-color: var(--primary);
  background: #181408;
}

.vsc-card__header {
  display: flex; align-items: center; gap: .8rem; margin-bottom: .6rem;
}
.vsc-card__logo {
  width: 38px; height: 38px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; flex-shrink: 0;
}
.vsc-card__logo--bazaar { background: rgba(0,255,157,.1); color: var(--primary); }
.vsc-card__logo--myket  { background: rgba(61,158,255,.1); color: var(--accent); }

.vsc-card__meta { flex: 1; }
.vsc-card__name { display: block; font-weight: 800; font-size: .92rem; color: var(--primary); }
.vsc-card__pub  { font-size: .72rem; color: #555; }

.vsc-card__install {
  display: inline-flex; align-items: center; gap: .3rem;
  background: rgba(0,255,157,.1);
  border: 1px solid rgba(0,255,157,.25);
  color: var(--primary); font-size: .78rem; font-weight: 700;
  padding: .35rem .8rem; border-radius: 4px; cursor: pointer;
  font-family: var(--font);
  transition: background var(--transition), border-color var(--transition);
}
.vsc-card__install:hover { background: rgba(0,255,157,.2); border-color: var(--primary); }

.vsc-card__desc { font-size: .8rem; color: #666; margin-bottom: .7rem; line-height: 1.6; }

.vsc-card__footer {
  display: flex; align-items: center; gap: 1rem;
  font-size: .73rem; color: #555;
}
.vsc-card__footer .mdi { color: var(--accent); font-size: .85rem; }
.vsc-card__tag {
  margin-right: auto;
  background: rgba(157,78,255,.1);
  color: var(--purple);
  border: 1px solid rgba(157,78,255,.2);
  padding: .1rem .55rem; border-radius: 3px;
  font-size: .68rem; font-weight: 700;
}

/* Preview (phone mockup) */
.vsc-preview {
  background: var(--dark);
  border-right: 1px solid #1e1e1e;
  display: flex; flex-direction: column;
  align-items: center; padding: 1rem .8rem; gap: .8rem;
}
.vsc-preview__label {
  font-size: .7rem; color: #444;
  display: flex; align-items: center; gap: .3rem;
  align-self: flex-start;
}
.vsc-preview__label .mdi { color: var(--primary); }

.vsc-phone {
  position: relative;
  width: 140px; height: 270px;
  background: #111;
  border-radius: 18px;
  border: 1.5px solid #2a2a2a;
  overflow: hidden;
  padding: 1.2rem .7rem .7rem;
  box-shadow: 0 10px 40px rgba(0,0,0,.6), inset 0 1px 0 rgba(255,255,255,.05);
}
.vsc-phone__notch {
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 50px; height: 16px; background: var(--dark);
  border-radius: 0 0 8px 8px;
}
.vsc-phone__glow {
  position: absolute; inset: -2px; border-radius: 18px; z-index: -1;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  opacity: .18; filter: blur(8px);
}

.vsc-app { display: flex; flex-direction: column; gap: .5rem; }
.vsc-app__bar {
  display: flex; align-items: center; gap: .3rem;
  padding-bottom: .4rem;
  border-bottom: 1px solid #222;
}
.vsc-app__logo { font-size: 1rem; color: var(--primary); }
.vsc-app__name { font-size: .65rem; font-weight: 800; color: var(--primary); }

.vsc-app__card {
  background: rgba(0,255,157,.06);
  border: 1px solid rgba(0,255,157,.14);
  border-radius: 6px; padding: .5rem; text-align: center;
}
.vsc-app__expr {
  font-size: 1rem; font-weight: 900; direction: ltr; color: var(--primary);
}
.vsc-app__expr mark { background: none; color: var(--accent); }
.vsc-app__label { font-size: .55rem; color: #666; margin-top: .2rem; }

.vsc-app__opts { display: flex; flex-direction: column; gap: .3rem; }
.vsc-app__opt {
  padding: .3rem; border-radius: 4px; text-align: center;
  font-size: .62rem; font-weight: 700; direction: ltr;
  background: #0a0a0a; border: 1px solid #1a1a1a; color: #444;
}
.vsc-app__opt--on {
  background: rgba(0,255,157,.08);
  border-color: rgba(0,255,157,.25); color: var(--primary);
}

.vsc-app__prog {
  height: 3px; background: #1a1a1a; border-radius: 99px; overflow: hidden;
}
.vsc-app__prog-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 99px;
}

/* Statusbar */
.vsc-statusbar {
  background: linear-gradient(90deg, var(--primary) 0%, var(--accent) 100%);
  display: flex; align-items: center; gap: 1.5rem;
  padding: 0 1rem; height: 24px;
  font-size: .7rem; font-weight: 700; color: #050505;
}
.vsc-statusbar .mdi { font-size: .85rem; }
.vsc-statusbar__right { margin-right: auto; }

/* Responsive */
@media (max-width: 860px) {
  .vsc-body { grid-template-columns: 48px 1fr; }
  .vsc-preview { display: none; }
}
@media (max-width: 560px) {
  .vsc-body { grid-template-columns: 1fr; }
  .vsc-sidebar { display: none; }
}

/* ══════════════════════════════════════════════════
   DOWNLOAD
══════════════════════════════════════════════════ */
.download { padding: 7rem 0; }

.download__card {
  position: relative; overflow: hidden;
  background: #111;
  border: 1px solid #2a2a2a;
  border-radius: var(--radius-xl);
  padding: 4.5rem;
  display: flex; align-items: center;
  justify-content: space-between; gap: 3rem;
}
.download__glow {
  position: absolute;
  width: 500px; height: 500px;
  background: var(--primary);
  border-radius: 50%; filter: blur(120px); opacity: .06;
  top: -150px; right: -100px;
  pointer-events: none;
}
.download__text h2 {
  font-size: clamp(1.7rem, 3vw, 2.4rem);
  font-weight: 900; margin-bottom: .55rem;
}
.download__text p {
  color: var(--muted); margin-bottom: 2.2rem; font-size: .97rem;
}
.download__btns { display: flex; gap: 1rem; flex-wrap: wrap; }

.store-btn {
  display: inline-flex; align-items: center; gap: .9rem;
  background: rgba(0,255,157,.04);
  border: 1px solid rgba(0,255,157,.15);
  border-radius: var(--radius);
  padding: .85rem 1.6rem;
  text-decoration: none; color: var(--text);
  transition: transform var(--transition), border-color var(--transition), background var(--transition);
  min-width: 160px;
}
.store-btn:hover {
  transform: translateY(-3px);
  border-color: var(--primary);
  background: rgba(0,255,157,.1);
  box-shadow: 0 0 20px rgba(0,255,157,.12);
}
.store-btn--myket:hover { border-color: var(--accent); background: rgba(61,158,255,.08); }
.store-btn__icon { font-size: 2.2rem; color: var(--primary); flex-shrink: 0; }
.store-btn--myket .store-btn__icon { color: var(--accent); }
.store-btn span { display: flex; flex-direction: column; line-height: 1.3; }
.store-btn small { font-size: .68rem; color: var(--muted); }
.store-btn strong { font-size: 1rem; font-weight: 800; }

.download__visual {
  position: relative; z-index: 1; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}

/* ── Download Phone Mockup ── */
.dl-phone {
  position: relative;
  width: 130px; height: 248px;
  background: #050505;
  border-radius: 22px;
  border: 1.5px solid rgba(0,255,157,.2);
  overflow: hidden;
  padding: 1rem .65rem .8rem;
  box-shadow:
    0 32px 80px rgba(0,0,0,.85),
    0 0 50px rgba(0,255,157,.1),
    0 0 20px rgba(61,158,255,.07),
    inset 0 1px 0 rgba(0,255,157,.07);
}
.dl-phone__notch {
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 44px; height: 12px;
  background: #050505;
  border-radius: 0 0 7px 7px;
  z-index: 5;
}
.dl-phone__glow {
  position: absolute; inset: -3px; border-radius: 24px; z-index: -1;
  background: linear-gradient(135deg, var(--primary), var(--accent), var(--hot));
  opacity: .22; filter: blur(12px);
}
.dl-phone__screen {
  width: 100%; height: 100%;
  display: flex; flex-direction: column; gap: .45rem;
}

/* status bar */
.dl-status {
  display: flex; justify-content: space-between; align-items: center;
  font-size: .48rem; color: #444; padding: 0 .1rem .3rem;
  border-bottom: 1px solid #111;
}
.dl-status__time { color: #666; font-weight: 700; }
.dl-status__icons { display: flex; gap: .2rem; }
.dl-status__icons .mdi { font-size: .7rem; color: #444; }

/* app header */
.dl-app-header {
  display: flex; align-items: center; gap: .35rem;
}
.dl-app-header .mdi { font-size: 1rem; color: var(--primary); }
.dl-app-name { font-size: .6rem; font-weight: 900; color: var(--primary); }

/* score strip */
.dl-score-strip {
  display: flex; justify-content: space-between; align-items: center;
  background: rgba(0,255,157,.06);
  border: 1px solid rgba(0,255,157,.14);
  border-radius: 5px;
  padding: .25rem .45rem;
}
.dl-score-strip__label { font-size: .48rem; color: #555; }
.dl-score-strip__val   { font-size: .72rem; font-weight: 900; color: var(--primary); text-shadow: 0 0 8px rgba(0,255,157,.5); }

/* problem card */
.dl-prob {
  background: rgba(61,158,255,.05);
  border: 1px solid rgba(61,158,255,.14);
  border-radius: 7px;
  padding: .55rem .45rem;
  text-align: center;
  flex: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .3rem;
}
.dl-prob__expr {
  font-size: .88rem; font-weight: 900; direction: ltr; color: var(--accent);
  text-shadow: 0 0 12px rgba(61,158,255,.4);
  line-height: 1.4;
}
.dl-prob__expr mark { background: none; color: var(--primary); }
.dl-prob__step { font-size: .5rem; color: #555; direction: rtl; }

/* answer options */
.dl-opts { display: flex; flex-direction: column; gap: .22rem; }
.dl-opt {
  padding: .26rem; border-radius: 4px; text-align: center;
  font-size: .58rem; font-weight: 700; direction: ltr;
  background: #0a0a0a; border: 1px solid #181818; color: #333;
}
.dl-opt--on {
  background: rgba(0,255,157,.1);
  border-color: rgba(0,255,157,.3); color: var(--primary);
  box-shadow: 0 0 8px rgba(0,255,157,.15);
}

/* progress bar */
.dl-prog {
  height: 2px; background: #111; border-radius: 99px; overflow: hidden;
}
.dl-prog__fill {
  height: 100%; width: 62%;
  background: linear-gradient(90deg, var(--primary), var(--accent), var(--hot));
  border-radius: 99px;
}

.footer__heart { color: var(--primary); font-size: .85rem; vertical-align: middle; }

/* ══════════════════════════════════════════════════
   FOOTER
══════════════════════════════════════════════════ */
.footer {
  padding: 2.2rem 0;
  border-top: 1px solid var(--border);
  background: var(--dark);
}
.footer__inner {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 1rem;
}
.footer__logo { font-weight: 800; font-size: 1rem; }
.footer__copy { font-size: .8rem; color: var(--muted); }
.footer__links {
  display: flex; gap: 1.5rem;
}
.footer__links a {
  font-size: .8rem; color: var(--muted);
  text-decoration: none; transition: color var(--transition);
}
.footer__links a:hover { color: var(--primary); }

/* ══════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════ */
@media (max-width: 960px) {
  .hero__inner    { grid-template-columns: 1fr; gap: 3rem; padding-top: 2rem; }
  .hero__visual   { order: -1; }
  .features__grid { grid-template-columns: repeat(2, 1fr); }
  .how__steps     { flex-wrap: wrap; justify-content: center; gap: 2rem; }
  .how__arrow     { display: none; }
  .how__step      { max-width: 160px; }
  .download__card { flex-direction: column; padding: 2.5rem 1.8rem; text-align: center; }
  .download__btns { justify-content: center; }
  .download__visual { display: none; }
}

@media (max-width: 600px) {
  .features__grid  { grid-template-columns: 1fr; }
  .hero__stats     { flex-direction: column; gap: .8rem; }
  .stat__divider   { width: 50px; height: 1px; }
  .nav__links a:not(.btn) { display: none; }
  .floating-card--3 { display: none; }
}


