/* ============================================================
   style.css — RootPath styles
   ============================================================ */

/* ── CSS VARIABLES ─────────────────────────────────────────── */
:root {
  --bg:       #0d1117;
  --surface:  #111827;
  --surface2: #1a2332;
  --border:   #1f2937;
  --border2:  #374151;
  --green:    #22c55e;
  --green2:   #4ade80;
  --green3:   #86efac;
  --green4:   #d1fae5;
  --text:     #f9fafb;
  --text2:    #9ca3af;
  --text3:    #6b7280;
  --text4:    #4b5563;
  --red:      #f87171;
  --blue:     #60a5fa;
  --amber:    #fbbf24;
  --mono:     'JetBrains Mono', monospace;
  --sans:     system-ui, -apple-system, sans-serif;
  --r:        8px;
}

/* ── RESET ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; background: var(--bg); color: var(--text); font-family: var(--sans); font-size: 14px; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: var(--sans); }

/* scrollbar */
::-webkit-scrollbar              { width: 4px; height: 4px; }
::-webkit-scrollbar-track        { background: transparent; }
::-webkit-scrollbar-thumb        { background: var(--border2); border-radius: 2px; }

/* ── PAGE SHELL ─────────────────────────────────────────────── */
.page        { display: none; flex-direction: column; min-height: 100vh; }
.page.active { display: flex; }

/* ── TOPBAR ─────────────────────────────────────────────────── */
.topbar {
  display: flex; align-items: center; gap: 10px;
  padding: 0 24px; height: 58px;
  background: var(--surface); border-bottom: 1px solid var(--border);
  flex-shrink: 0; position: sticky; top: 0; z-index: 100;
}
.logo        { display: flex; align-items: center; gap: 9px; cursor: pointer; user-select: none; }
.logo-svg    { width: 32px; height: 32px; flex-shrink: 0; }
.logo-name   { font-family: var(--mono); font-size: 16px; font-weight: 700; color: var(--text); }
.logo-name span { color: var(--green); }
.topbar-nav  { display: flex; gap: 3px; margin-left: 10px; }
.tnav-btn {
  padding: 7px 16px; border-radius: 7px; border: none;
  background: transparent; font-size: 13px; font-weight: 500;
  color: var(--text3); transition: all .15s;
}
.tnav-btn:hover  { background: var(--border); color: var(--text2); }
.tnav-btn.active { background: var(--border); color: var(--green); }
.topbar-right { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.icon-btn {
  width: 34px; height: 34px; border-radius: 7px; border: none;
  background: transparent; color: var(--text3);
  display: flex; align-items: center; justify-content: center; transition: all .15s;
}
.icon-btn:hover { background: var(--border); color: var(--text); }
.avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--green); display: flex; align-items: center;
  justify-content: center; font-size: 12px; font-weight: 700;
  color: #052e16; cursor: pointer;
}

/* ── BUTTONS ─────────────────────────────────────────────────── */
.btn-primary {
  padding: 9px 20px; border-radius: var(--r); border: none;
  background: var(--green); color: #052e16;
  font-size: 13px; font-weight: 700; font-family: var(--mono); transition: opacity .15s;
}
.btn-primary:hover { opacity: .88; }
.btn-outline {
  padding: 8px 18px; border-radius: var(--r);
  border: 1px solid var(--border2); background: transparent;
  color: var(--text2); font-size: 13px; transition: all .15s;
}
.btn-outline:hover { background: var(--border); color: var(--text); }

/* ── FOOTER ─────────────────────────────────────────────────── */
.footer {
  display: flex; align-items: center; padding: 10px 24px;
  gap: 14px; flex-wrap: wrap;
  background: var(--surface); border-top: 1px solid var(--border);
}
.footer-brand { font-family: var(--mono); font-size: 12px; color: var(--text4); }
.footer-brand b { color: var(--green); }
.fsep { width: 1px; height: 14px; background: var(--border2); flex-shrink: 0; }
.footer-socials { display: flex; gap: 4px; flex-wrap: wrap; }
.social-btn {
  display: flex; align-items: center; gap: 5px; padding: 5px 10px;
  border-radius: 6px; border: 1px solid var(--border2); background: transparent;
  font-size: 12px; color: var(--text3); transition: all .12s;
}
.social-btn:hover { background: var(--border); color: var(--text); border-color: var(--text4); }
.sico { width: 13px; height: 13px; fill: currentColor; flex-shrink: 0; }
.footer-right { margin-left: auto; font-size: 11px; color: var(--text4); }
.footer-right a { color: var(--green); }

/* ── LANDING ─────────────────────────────────────────────────── */
.hero {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  justify-content: center; padding: 64px 24px 48px;
  text-align: center; position: relative; overflow: hidden;
}
.hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 40px 40px; opacity: .25; pointer-events: none;
}
.hero-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 14px; border-radius: 20px;
  border: 1px solid #14532d; background: #0a1f12;
  font-size: 12px; color: var(--green3); font-family: var(--mono); margin-bottom: 24px;
}
.hero-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .4; } }
.hero h1 { font-size: clamp(32px, 6vw, 60px); font-weight: 700; line-height: 1.12; color: var(--text); max-width: 740px; margin-bottom: 18px; }
.hero h1 .acc { color: var(--green); }
.hero p { font-size: 16px; color: var(--text2); max-width: 520px; line-height: 1.7; margin-bottom: 32px; }
.hero-btns { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.hero-terminal { margin-top: 52px; background: #000; border: 1px solid var(--border2); border-radius: 12px; max-width: 580px; width: 100%; overflow: hidden; }
.ht-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; background: var(--surface); border-bottom: 1px solid var(--border); }
.ht-dot { width: 10px; height: 10px; border-radius: 50%; }
.ht-title { font-size: 11px; color: var(--text4); font-family: var(--mono); margin: 0 auto; }
.ht-body { padding: 16px 18px; font-family: var(--mono); font-size: 12px; line-height: 1.85; text-align: left; }
.ht-g { color: var(--green); } .ht-b { color: var(--blue); } .ht-w { color: var(--text); } .ht-m { color: var(--text3); } .ht-a { color: var(--green2); }

.stats-banner { background: var(--surface); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 32px 24px; }
.stats-inner { display: flex; justify-content: center; gap: 60px; flex-wrap: wrap; max-width: 800px; margin: 0 auto; }
.stat-item { text-align: center; }
.sn { font-family: var(--mono); font-size: 34px; font-weight: 700; color: var(--green); }
.sl { font-size: 12px; color: var(--text3); margin-top: 4px; }

.section { padding: 60px 24px; max-width: 1080px; margin: 0 auto; width: 100%; }
.sec-label { font-size: 11px; color: var(--green); font-family: var(--mono); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 8px; }
.sec-title { font-size: clamp(22px, 4vw, 32px); font-weight: 700; color: var(--text); margin-bottom: 12px; }
.sec-sub   { font-size: 15px; color: var(--text2); line-height: 1.7; max-width: 560px; margin-bottom: 36px; }

.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.feat-card { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 22px; transition: border-color .15s; }
.feat-card:hover { border-color: var(--border2); }
.feat-icon { width: 38px; height: 38px; border-radius: 8px; background: #0a1f12; border: 1px solid #14532d; display: flex; align-items: center; justify-content: center; margin-bottom: 14px; }
.feat-icon svg { width: 18px; height: 18px; stroke: var(--green); fill: none; stroke-width: 2; stroke-linecap: round; }
.feat-title { font-size: 14px; font-weight: 500; color: var(--text); margin-bottom: 6px; }
.feat-text  { font-size: 12px; color: var(--text3); line-height: 1.7; }

.mod-row  { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.mod-mini { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 16px; cursor: pointer; transition: all .15s; }
.mod-mini:hover { border-color: var(--green); background: var(--surface2); }
.mm-num { font-family: var(--mono); font-size: 10px; color: var(--text4); margin-bottom: 8px; }
.mm-title { font-size: 13px; font-weight: 500; color: var(--text); margin-bottom: 4px; }
.mm-count { font-size: 11px; color: var(--text3); }
.mm-status { display: flex; align-items: center; gap: 5px; margin-top: 10px; font-size: 11px; }
.mm-dot { width: 6px; height: 6px; border-radius: 50%; }

.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; }
.step { padding: 20px; border-left: 2px solid var(--border); }
.step.as { border-left-color: var(--green); }
.step-num   { font-family: var(--mono); font-size: 11px; color: var(--green); margin-bottom: 8px; }
.step-title { font-size: 14px; font-weight: 500; color: var(--text); margin-bottom: 6px; }
.step-text  { font-size: 12px; color: var(--text3); line-height: 1.65; }

/* ── ABOUT PAGE ─────────────────────────────────────────────── */
.about-page-body { flex: 1; max-width: 860px; margin: 0 auto; width: 100%; padding: 40px 24px; }
.about-hero { display: flex; align-items: flex-start; gap: 24px; margin-bottom: 40px; flex-wrap: wrap; }
.about-av   { width: 72px; height: 72px; border-radius: 50%; background: var(--green); display: flex; align-items: center; justify-content: center; font-size: 26px; font-weight: 700; color: #052e16; flex-shrink: 0; }
.about-intro h2 { font-size: 22px; font-weight: 600; color: var(--text); margin-bottom: 4px; }
.about-intro p  { font-size: 13px; color: var(--text3); margin-bottom: 10px; }
.about-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.atag { font-size: 11px; padding: 3px 10px; border-radius: 10px; border: 1px solid var(--border2); color: var(--text3); font-family: var(--mono); }
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 32px; }
.about-card { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 22px; }
.ac-title { font-size: 13px; font-weight: 500; color: var(--text); margin-bottom: 10px; }
.ac-text  { font-size: 12px; color: var(--text2); line-height: 1.75; }
.ac-text p { margin-bottom: 8px; }
.ac-text p:last-child { margin-bottom: 0; }
.about-quote { background: #0a1f12; border: 1px solid #14532d; border-radius: 12px; padding: 20px 24px; margin-bottom: 32px; }
.aq-text { font-size: 15px; color: var(--green4); line-height: 1.7; font-style: italic; margin-bottom: 8px; }
.aq-attr { font-size: 11px; color: var(--green3); font-family: var(--mono); }
.connect-row { display: flex; gap: 10px; flex-wrap: wrap; }
.connect-btn { display: flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 8px; border: 1px solid var(--border2); background: var(--surface); font-size: 12px; color: var(--text2); transition: all .12s; }
.connect-btn:hover { background: var(--border); color: var(--text); border-color: var(--text4); }

/* ── LESSONS PAGE ───────────────────────────────────────────── */
.lp-body  { flex: 1; padding: 32px 24px; max-width: 1100px; margin: 0 auto; width: 100%; }
.lp-title { font-size: 26px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.lp-sub   { font-size: 13px; color: var(--text3); }
.op-bar-wrap { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 14px 20px; margin: 16px 0 24px; display: flex; align-items: center; gap: 16px; }
.op-lbl  { font-size: 12px; color: var(--text2); flex-shrink: 0; }
.op-bar  { flex: 1; height: 5px; background: var(--border2); border-radius: 3px; }
.op-fill { height: 100%; background: var(--green); border-radius: 3px; }
.op-pct  { font-family: var(--mono); font-size: 12px; color: var(--green); flex-shrink: 0; }
.mod-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.mc { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; transition: border-color .15s; }
.mc.unlocked:hover { border-color: var(--green); }
.mc-head  { padding: 16px 18px; display: flex; align-items: flex-start; gap: 12px; border-bottom: 1px solid var(--border); }
.mc-icon  { width: 38px; height: 38px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.mc-icon.done   { background: #0a1f12; border: 1px solid #14532d; }
.mc-icon.inprog { background: #0a1f12; border: 1px solid var(--green); }
.mc-icon.locked { background: var(--surface2); border: 1px solid var(--border); }
.mc-info  { flex: 1; }
.mc-tag   { font-size: 10px; font-family: var(--mono); margin-bottom: 4px; }
.mc-tag.done   { color: var(--green); }
.mc-tag.inprog { color: var(--green2); }
.mc-tag.locked { color: var(--text4); }
.mc-title2 { font-size: 14px; font-weight: 500; color: var(--text); }
.mc-body2  { padding: 14px 18px; }
.mc-desc   { font-size: 12px; color: var(--text3); line-height: 1.65; margin-bottom: 12px; }
.lr { display: flex; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 6px; font-size: 12px; color: var(--text3); background: var(--bg); border: 1px solid var(--border); cursor: pointer; transition: all .12s; margin-bottom: 5px; }
.lr:hover  { border-color: var(--green); color: var(--green4); }
.lr.done   { color: var(--text4); }
.lr.active { border-color: var(--green); color: var(--green4); background: #0a1f12; }
.lr.locked { opacity: .4; cursor: default; }
.lr.locked:hover { border-color: var(--border); color: var(--text3); }
.lr-dot    { width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0; }
.lr-dot.done { background: var(--green); }
.lr-dot.act  { background: var(--green); box-shadow: 0 0 6px var(--green); }
.lr-dot.lock { background: var(--border2); }
.lr-name   { flex: 1; }
.lr-time   { font-family: var(--mono); font-size: 10px; color: var(--text4); }
.mc-prog      { height: 3px; background: var(--border); margin-top: 10px; border-radius: 2px; }
.mc-prog-fill { height: 100%; background: var(--green); border-radius: 2px; }

/* ── CHALLENGES PAGE ────────────────────────────────────────── */
.ch-body { flex: 1; padding: 32px 24px; max-width: 1100px; margin: 0 auto; width: 100%; }
.ch-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; margin-top: 24px; }
.ch-card { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 20px; transition: border-color .15s; cursor: pointer; }
.ch-card:hover { border-color: var(--green); }
.ch-card.locked-ch { opacity: .5; cursor: default; }
.ch-card.locked-ch:hover { border-color: var(--border); }
.ch-top    { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.ch-badge  { font-family: var(--mono); font-size: 10px; padding: 3px 8px; border-radius: 5px; }
.ch-badge.easy   { background: #0a2e1a; color: var(--green);  border: 1px solid #14532d; }
.ch-badge.medium { background: #2d1b00; color: var(--amber);  border: 1px solid #92400e; }
.ch-badge.hard   { background: #2d0a0a; color: var(--red);    border: 1px solid #7f1d1d; }
.ch-pts   { margin-left: auto; font-family: var(--mono); font-size: 11px; color: var(--text4); }
.ch-title { font-size: 14px; font-weight: 500; color: var(--text); margin-bottom: 6px; }
.ch-desc  { font-size: 12px; color: var(--text3); line-height: 1.6; margin-bottom: 12px; }
.ch-tags  { display: flex; gap: 5px; flex-wrap: wrap; }
.ch-tag   { font-size: 10px; padding: 2px 8px; border-radius: 4px; background: var(--surface2); color: var(--text4); font-family: var(--mono); }

/* ── DOCS PAGE ──────────────────────────────────────────────── */
.docs-layout  { flex: 1; display: flex; min-height: 0; }
.docs-sidebar { width: 220px; background: var(--surface); border-right: 1px solid var(--border); padding: 16px 0; overflow-y: auto; flex-shrink: 0; }
.docs-sec  { padding: 10px 16px 4px; font-size: 10px; color: var(--text4); text-transform: uppercase; letter-spacing: .06em; }
.docs-link { display: block; padding: 7px 16px; font-size: 12px; color: var(--text2); cursor: pointer; transition: all .12s; border-left: 2px solid transparent; }
.docs-link:hover  { background: var(--border); color: var(--text); }
.docs-link.active { background: #0f2818; color: var(--green); border-left-color: var(--green); }
.docs-content { flex: 1; padding: 32px; overflow-y: auto; max-width: 760px; }
.docs-content h2 { font-size: 22px; font-weight: 600; color: var(--text); margin-bottom: 8px; padding-bottom: 10px; border-bottom: 1px solid var(--border); }
.docs-content h3 { font-size: 15px; font-weight: 500; color: var(--text); margin: 20px 0 8px; }
.docs-content p  { font-size: 13px; color: var(--text2); line-height: 1.75; margin-bottom: 12px; }
.docs-content pre { background: #000; border: 1px solid var(--border); border-radius: 6px; padding: 12px 14px; font-family: var(--mono); font-size: 12px; color: var(--green3); overflow-x: auto; margin-bottom: 12px; line-height: 1.7; }
.docs-content ul  { padding-left: 20px; margin-bottom: 12px; }
.docs-content li  { font-size: 13px; color: var(--text2); line-height: 1.75; margin-bottom: 4px; }
.docs-content code { font-family: var(--mono); background: var(--surface2); color: var(--green2); padding: 1px 6px; border-radius: 4px; font-size: 12px; }
.cmd-table { width: 100%; border-collapse: collapse; margin-bottom: 16px; }
.cmd-table th { text-align: left; padding: 8px 12px; font-size: 11px; color: var(--text4); border-bottom: 1px solid var(--border); font-weight: 500; }
.cmd-table td { padding: 8px 12px; font-size: 12px; border-bottom: 1px solid var(--border); }
.cmd-table td:first-child { font-family: var(--mono); color: var(--green2); }
.cmd-table td:last-child  { color: var(--text3); }

/* ── TERMINAL PAGE ──────────────────────────────────────────── */
.app-body { display: flex; flex: 1; min-height: 0; overflow: hidden; }
.sidebar  { width: 200px; background: var(--surface); border-right: 1px solid var(--border); display: flex; flex-direction: column; flex-shrink: 0; overflow-y: auto; }
.sb-sec   { padding: 14px 14px 5px; font-size: 10px; font-weight: 500; color: var(--text4); letter-spacing: .06em; text-transform: uppercase; }
.sb-item  { display: flex; align-items: center; gap: 8px; padding: 7px 14px; font-size: 12px; color: var(--text2); cursor: pointer; border-left: 2px solid transparent; transition: all .12s; }
.sb-item:hover { background: var(--border); color: var(--text); }
.sb-item.sa    { background: #0f2818; color: var(--green); border-left-color: var(--green); }
.sb-item.sd    { color: var(--text3); }
.sb-item.sd .sbi { color: var(--green); }
.sb-item.sl    { opacity: .4; cursor: default; }
.sb-item.sl:hover { background: transparent; color: var(--text2); }
.sbi { font-size: 13px; width: 16px; text-align: center; flex-shrink: 0; }
.sb-badge { margin-left: auto; font-size: 10px; padding: 2px 6px; border-radius: 10px; background: #14532d; color: var(--green3); font-family: var(--mono); }
.sb-progress { padding: 12px 14px 6px; }
.sp-lbl  { font-size: 11px; color: var(--text3); margin-bottom: 5px; display: flex; justify-content: space-between; }
.sp-bar  { height: 3px; background: var(--border2); border-radius: 2px; }
.sp-fill { height: 100%; background: var(--green); border-radius: 2px; transition: width .4s; }

.main-col     { flex: 1; display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.lesson-topbar { display: flex; align-items: center; gap: 10px; padding: 8px 16px; background: var(--surface); border-bottom: 1px solid var(--border); flex-shrink: 0; }
.lt-ey   { font-size: 10px; color: var(--text4); white-space: nowrap; }
.lt-ti   { font-size: 12px; color: var(--green4); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 240px; margin-left: 4px; }
.lt-bar  { flex: 1; height: 3px; background: var(--border2); border-radius: 2px; margin: 0 8px; }
.lt-fill { height: 100%; background: var(--green); border-radius: 2px; transition: width .3s; }
.lt-step { font-size: 11px; color: var(--text3); white-space: nowrap; font-family: var(--mono); }

.workspace { flex: 1; display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.tcol      { flex: 1; display: flex; flex-direction: column; padding: 14px; min-height: 0; gap: 10px; }

/* theory */
.theory-panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r); padding: 14px 16px; font-size: 12px; color: var(--text2); line-height: 1.7; overflow-y: auto; max-height: 190px; flex-shrink: 0; }
.theory-panel h3         { font-size: 13px; font-weight: 500; color: var(--text); margin: 10px 0 6px; }
.theory-panel h3:first-child { margin-top: 0; }
.theory-panel p          { margin-bottom: 8px; }
.theory-panel pre        { background: #000; border: 1px solid var(--border); border-radius: 5px; padding: 8px 10px; font-family: var(--mono); font-size: 11px; color: var(--green3); overflow-x: auto; margin-bottom: 8px; line-height: 1.6; }
.theory-panel ul         { padding-left: 16px; margin-bottom: 8px; }
.theory-panel li         { margin-bottom: 3px; }
.theory-panel code       { font-family: var(--mono); background: var(--surface2); color: var(--green2); padding: 1px 5px; border-radius: 3px; font-size: 11px; }
.theory-panel strong     { color: var(--text); font-weight: 500; }
.theory-panel em         { color: var(--green3); font-style: italic; }

/* task card */
.task-card  { background: #0a1f12; border: 1px solid #14532d; border-radius: var(--r); padding: 10px 14px; display: flex; gap: 10px; flex-shrink: 0; }
.tc-icon    { color: var(--green); font-size: 16px; margin-top: 1px; flex-shrink: 0; }
.tc-body    { font-size: 12px; color: var(--green3); line-height: 1.6; }
.tc-body strong { color: var(--green4); font-weight: 500; }
.task-cmd   { font-family: var(--mono); background: #1a3a22; color: var(--green2); padding: 1px 6px; border-radius: 4px; font-size: 11px; }

/* terminal */
.terminal   { flex: 1; background: #000; border-radius: var(--r); border: 1px solid var(--border); padding: 14px 16px; font-family: var(--mono); font-size: 12.5px; line-height: 1.75; overflow-y: auto; display: flex; flex-direction: column; min-height: 0; }
.t-out      { flex: 1; }
.t-row      { display: block; }
.tp  { color: var(--green); }
.tpa { color: var(--blue);  }
.tc2 { color: var(--text);  }
.tr2 { color: var(--text2); }
.te  { color: var(--red);   }
.tco { color: var(--text4); }
.t-iw { display: flex; align-items: center; margin-top: 4px; }
.t-ip { color: var(--green); white-space: nowrap; font-family: var(--mono); font-size: 12.5px; }
#termInput, #freeInput { background: transparent; border: none; outline: none; color: var(--text); font-family: var(--mono); font-size: 12.5px; flex: 1; caret-color: var(--green); }
.cursor { display: inline-block; width: 7px; height: 14px; background: var(--green); vertical-align: middle; animation: blink 1s step-end infinite; }
@keyframes blink { 0%,100% { opacity: 1; } 50% { opacity: 0; } }

/* action bar */
.action-bar { display: flex; align-items: center; gap: 8px; padding: 10px 14px; background: var(--surface); border-top: 1px solid var(--border); flex-shrink: 0; }
.act-btn { display: flex; align-items: center; gap: 5px; padding: 5px 12px; border-radius: 6px; border: 1px solid var(--border2); background: transparent; font-size: 11px; color: var(--text3); transition: all .12s; }
.act-btn:hover { background: var(--border); color: var(--text); }
.run-btn { margin-left: auto; padding: 7px 18px; border-radius: 6px; border: none; background: var(--green); color: #052e16; font-size: 12px; font-weight: 700; font-family: var(--mono); transition: opacity .12s; }
.run-btn:hover { opacity: .88; }

/* about panel */
.about-panel { width: 256px; background: var(--surface); border-left: 1px solid var(--border); display: flex; flex-direction: column; overflow-y: auto; flex-shrink: 0; }
.ap-hdr   { padding: 14px 16px 10px; border-bottom: 1px solid var(--border); }
.ap-tag   { font-size: 10px; color: var(--text4); letter-spacing: .06em; text-transform: uppercase; margin-bottom: 5px; }
.ap-title { font-size: 15px; font-weight: 500; color: var(--text); }
.ap-body  { padding: 14px 16px; display: flex; flex-direction: column; gap: 14px; }
.ap-slbl  { font-size: 10px; color: var(--text4); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 5px; }
.ap-text  { font-size: 12px; color: var(--text2); line-height: 1.7; }
.ap-div   { height: 1px; background: var(--border); }
.c-card   { background: var(--bg); border: 1px solid var(--border); border-radius: var(--r); padding: 12px; }
.c-top    { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.c-av     { width: 36px; height: 36px; border-radius: 50%; background: var(--green); display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; color: #052e16; flex-shrink: 0; }
.c-name   { font-size: 13px; font-weight: 500; color: var(--text); }
.c-role   { font-size: 11px; color: var(--text3); margin-top: 1px; }
.c-bio    { font-size: 11px; color: var(--text2); line-height: 1.65; }
.stats-row { display: flex; gap: 8px; }
.stat-box  { flex: 1; background: var(--bg); border: 1px solid var(--border); border-radius: 6px; padding: 8px 10px; text-align: center; }
.sn2 { font-size: 16px; font-weight: 500; color: var(--green); font-family: var(--mono); }
.sl2 { font-size: 10px; color: var(--text4); margin-top: 2px; }
.ap-slink { display: flex; align-items: center; gap: 6px; padding: 6px 9px; border-radius: 6px; border: 1px solid var(--border); font-size: 11px; color: var(--text3); transition: all .12s; margin-bottom: 5px; }
.ap-slink:hover { background: var(--border); color: var(--text); }

/* page tabs */
.page-tabs { display: flex; gap: 2px; padding: 8px 14px; background: var(--surface); border-bottom: 1px solid var(--border); flex-shrink: 0; }
.ptab { padding: 6px 16px; border-radius: 6px; border: none; background: transparent; font-size: 12px; font-weight: 500; color: var(--text3); transition: all .15s; }
.ptab:hover  { background: var(--border); color: var(--text2); }
.ptab.active { background: var(--border); color: var(--green); }
.tab-panel        { display: none; flex: 1; flex-direction: column; min-height: 0; overflow: hidden; }
.tab-panel.active { display: flex; }

/* wasm */
.wasm-col   { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 32px 24px; gap: 16px; }
.wasm-note  { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 24px; max-width: 520px; width: 100%; text-align: center; }
.wasm-title { font-size: 16px; font-weight: 500; color: var(--text); margin-bottom: 8px; }
.wasm-text  { font-size: 12px; color: var(--text3); line-height: 1.7; margin-bottom: 16px; }

/* ── RESPONSIVE ─────────────────────────────────────────────── */
@media (max-width: 900px) {
  .sidebar, .about-panel { display: none; }
}
@media (max-width: 640px) {
  .topbar-nav { display: none; }
  .hero h1 { font-size: 28px; }
  .stats-inner { gap: 32px; }
  .hero-terminal { display: none; }
  .footer-right { display: none; }
  .about-grid { grid-template-columns: 1fr; }
  .docs-sidebar { display: none; }
}
