:root {
  --base: #090a0f;
  --panel: #11141c;
  --elevated: #161a24;
  --line: rgba(255,255,255,.08);
  --text: #f3f4f6;
  --muted: #9ca3af;
  --accent: #10b981;
  --bright: #00e676;
  --glow: 0 0 28px rgba(16,185,129,.28);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--base);
  color: var(--text);
  font-family: Inter, 'Segoe UI', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(900px 500px at 78% -8%, rgba(16,185,129,.13), transparent 60%),
    radial-gradient(700px 500px at 0% 40%, rgba(0,230,118,.05), transparent 60%);
  z-index: -1;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

#matrix { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; opacity: 0; z-index: 60; transition: opacity .5s; mix-blend-mode: screen; }
#matrix.on { opacity: .32; }

.topbar {
  position: sticky; top: 0; z-index: 40;
  height: 68px; display: flex; align-items: center; gap: 24px;
  padding: 0 clamp(20px, 5vw, 70px);
  background: rgba(9,10,15,.82); backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 9px; font-size: 14px; font-weight: 800; letter-spacing: .08em; }
.brand-mark { width: 15px; height: 15px; border-radius: 4px; background: linear-gradient(135deg,var(--accent),var(--bright)); transform: rotate(45deg); box-shadow: 0 0 14px rgba(0,230,118,.6); }
.brand-name { color: var(--text); }
.brand-slash, .brand-sub { color: #6b7280; font-weight: 500; letter-spacing: 0; }
.nav { display: flex; gap: 6px; margin-left: auto; }
.nav-link {
  background: transparent; border: 0; color: var(--muted);
  padding: 9px 14px; border-radius: 10px; font-size: 13px; font-weight: 500;
  transition: color .2s, background .2s;
}
.nav-link:hover { color: var(--text); background: rgba(255,255,255,.04); }
.nav-link.active { color: var(--bright); background: rgba(16,185,129,.1); }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid var(--line); background: rgba(255,255,255,.03); color: var(--text);
  padding: 12px 20px; border-radius: 12px; font-size: 13px; font-weight: 600;
  transition: transform .2s, box-shadow .2s, background .2s, border-color .2s;
}
.btn:hover { transform: translateY(-2px); border-color: rgba(16,185,129,.4); }
.btn-small { padding: 8px 14px; font-size: 12px; }
.btn-primary { background: linear-gradient(135deg,var(--accent),var(--bright)); color: #04150f; border: 0; box-shadow: var(--glow); }
.btn-primary:hover { box-shadow: 0 0 42px rgba(0,230,118,.4); }
.btn-ghost { background: transparent; }

main { max-width: 1180px; margin: 0 auto; padding: 0 clamp(20px,5vw,40px); }
.tab { display: none; padding: 70px 0 90px; animation: fade .4s ease both; }
.tab.active { display: block; }
@keyframes fade { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

.hero { display: grid; grid-template-columns: 1.05fr .95fr; gap: 60px; align-items: center; min-height: 620px; }
.pill { display: inline-flex; align-items: center; gap: 9px; border: 1px solid rgba(16,185,129,.28); background: rgba(16,185,129,.07); color: var(--bright); padding: 7px 13px; border-radius: 99px; font-size: 10px; font-weight: 700; letter-spacing: .14em; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--bright); box-shadow: 0 0 10px var(--bright); animation: blink 1.8s infinite; }
@keyframes blink { 50% { opacity: .35; } }
h1 { font-size: clamp(42px,5.5vw,68px); line-height: 1.05; margin: 22px 0 18px; letter-spacing: -.04em; }
h1 span { background: linear-gradient(135deg,var(--accent),var(--bright)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { color: var(--muted); font-size: 16px; line-height: 1.7; max-width: 540px; }
.hero-actions { display: flex; gap: 12px; margin: 30px 0 44px; flex-wrap: wrap; }
.stats { display: grid; grid-template-columns: repeat(4,1fr); gap: 12px; border-top: 1px solid var(--line); padding-top: 24px; }
.stats strong { display: block; font-size: 24px; color: var(--bright); letter-spacing: -.03em; }
.stats span { display: block; color: var(--muted); font-size: 11px; line-height: 1.4; margin-top: 5px; }

.hero-card { perspective: 1200px; }
.window { border: 1px solid var(--line); border-radius: 18px; overflow: hidden; background: var(--panel); box-shadow: 0 30px 80px -30px #000, var(--glow); transform: rotateY(-6deg) rotateX(3deg); transition: transform .4s; }
.window:hover { transform: rotateY(0) rotateX(0); }
.window-bar { height: 40px; display: flex; align-items: center; gap: 7px; padding: 0 14px; background: rgba(255,255,255,.02); border-bottom: 1px solid var(--line); }
.window-bar i { width: 9px; height: 9px; border-radius: 50%; background: #374151; }
.window-bar i:first-child { background: #ef4444; } .window-bar i:nth-child(2) { background: #f59e0b; } .window-bar i:nth-child(3) { background: var(--accent); }
.window-bar span { margin-left: 10px; color: #6b7280; font: 10px 'JetBrains Mono',monospace; }
.window-body { padding: 24px; }
.fake-banner { display: flex; align-items: center; gap: 16px; padding: 22px; border-radius: 14px; background: radial-gradient(circle at 85% 20%,rgba(16,185,129,.28),transparent 55%),linear-gradient(120deg,#101b18,#0d1119); border: 1px solid var(--line); margin-bottom: 20px; }
.fake-logo { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 14px; background: linear-gradient(135deg,var(--accent),var(--bright)); color: #04150f; font-size: 26px; font-weight: 900; }
.fake-banner b { display: block; font-size: 18px; } .fake-banner small { color: var(--muted); }
.fake-row { display: flex; justify-content: space-between; padding: 10px 4px; color: #cbd5e1; font-size: 12px; border-bottom: 1px solid rgba(255,255,255,.04); }
.fake-row span { color: var(--bright); } .fake-row b { color: var(--bright); }
.fake-play { margin-top: 18px; text-align: center; padding: 15px; border-radius: 12px; background: linear-gradient(135deg,var(--accent),var(--bright)); color: #04150f; font-weight: 900; letter-spacing: .1em; box-shadow: var(--glow); }

.section-head { margin-bottom: 38px; }
.eyebrow { color: var(--bright); font-size: 10px; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; margin: 0 0 12px; }
h2 { font-size: clamp(28px,4vw,42px); margin: 0 0 12px; letter-spacing: -.03em; }
.muted { color: var(--muted); line-height: 1.7; }
.small { font-size: 12px; }
.grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }
.card { padding: 26px; border: 1px solid var(--line); border-radius: 18px; background: rgba(17,20,28,.75); transition: transform .25s, border-color .25s, box-shadow .25s; }
.card:hover { transform: translateY(-4px); border-color: rgba(16,185,129,.35); box-shadow: var(--glow); }
.card-icon { font-size: 26px; margin-bottom: 14px; }
.card h3 { margin: 0 0 10px; font-size: 16px; }
.card p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.65; }

.download-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }
.download-card { display: block; padding: 28px; border: 1px solid var(--line); border-radius: 18px; background: var(--panel); transition: transform .25s; }
.download-card:hover { transform: translateY(-4px); border-color: var(--accent); }
.download-card.primary { background: linear-gradient(135deg,rgba(16,185,129,.16),rgba(17,20,28,.9)); border-color: rgba(16,185,129,.35); }
.download-card b { display: block; font-size: 17px; margin-bottom: 8px; }
.download-card span { display: block; color: var(--muted); font-size: 12px; }
.download-card em { display: block; margin-top: 22px; color: var(--bright); font-style: normal; font-size: 13px; font-weight: 600; }
.notice { margin-top: 22px; padding: 18px 20px; border-left: 3px solid var(--accent); background: rgba(16,185,129,.06); border-radius: 0 12px 12px 0; color: var(--muted); font-size: 13px; line-height: 1.6; }
.notice b { color: var(--text); }

.dev-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
.dev-text h3 { font-size: 21px; margin: 0 0 14px; }
.dev-text p { color: var(--muted); line-height: 1.75; font-size: 14px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 22px 0; }
.chips span { padding: 6px 11px; border: 1px solid var(--line); border-radius: 8px; background: rgba(255,255,255,.03); font: 11px 'JetBrains Mono',monospace; color: var(--bright); }
.meme { margin: 0; border: 1px solid var(--line); border-radius: 18px; overflow: hidden; background: var(--panel); box-shadow: 0 24px 60px -25px #000; }
.meme img { width: 100%; display: block; }
.meme figcaption { padding: 12px 16px; color: var(--muted); font-size: 12px; border-top: 1px solid var(--line); }

.footer { display: flex; justify-content: space-between; gap: 30px; flex-wrap: wrap; border-top: 1px solid var(--line); padding: 40px clamp(20px,5vw,70px); background: rgba(17,20,28,.45); }
.small-brand { font-size: 13px; }
.footer-links { display: flex; gap: 22px; color: var(--muted); font-size: 13px; align-items: center; }
.footer-links a:hover { color: var(--bright); }
.footer-legal { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.easter { border: 0; background: transparent; color: #6b7280; font-size: 12px; padding: 0; }
.easter:hover { color: var(--bright); text-decoration: underline dotted; }

.modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; background: rgba(0,0,0,.78); backdrop-filter: blur(8px); padding: 20px; }
.modal[hidden] { display: none; }
.modal-box { position: relative; max-width: 520px; width: 100%; max-height: 88vh; overflow: auto; padding: 30px; border: 1px solid rgba(16,185,129,.3); border-radius: 20px; background: var(--panel); box-shadow: 0 0 60px rgba(16,185,129,.18); }
.modal-box h2 { font-size: 26px; }
.modal-box p { color: var(--muted); line-height: 1.9; font-size: 13px; }
.modal-box img { width: 100%; border-radius: 12px; margin-top: 16px; }
.modal-box small { color: #6b7280; }
.modal-close { position: absolute; right: 18px; top: 14px; border: 0; background: transparent; color: var(--muted); font-size: 28px; line-height: 1; }
.modal-close:hover { color: var(--text); }

.toast { position: fixed; bottom: 26px; left: 50%; transform: translate(-50%,20px); z-index: 90; padding: 12px 20px; border: 1px solid rgba(16,185,129,.35); border-radius: 12px; background: rgba(17,20,28,.95); color: var(--bright); font-size: 13px; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; }
.toast.show { opacity: 1; transform: translate(-50%,0); }

/* ---- многостраничные разделы ---- */
.page-head { padding: 56px 0 30px; border-bottom: 1px solid var(--line); margin-bottom: 38px; }
.page-head h1 { font-size: clamp(34px,5vw,54px); margin: 10px 0 14px; }
.page-head p { max-width: 680px; }

.local-download { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; padding: 26px; border: 1px solid rgba(16,185,129,.35); border-radius: 18px; background: linear-gradient(135deg,rgba(16,185,129,.14),rgba(17,20,28,.9)); }
.local-download .big-btn { margin-left: auto; }
.hash { font: 11px 'JetBrains Mono',monospace; color: var(--muted); word-break: break-all; margin-top: 12px; }
.steps { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; margin-top: 28px; counter-reset: step; }
.step { padding: 22px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); }
.step::before { counter-increment: step; content: counter(step); display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: rgba(16,185,129,.15); color: var(--bright); font-size: 12px; font-weight: 800; margin-bottom: 12px; }
.step b { display: block; margin-bottom: 6px; }
.step p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }

.search-panel { display: flex; flex-wrap: wrap; gap: 10px; padding: 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); margin-bottom: 14px; }
.field { flex: 1; min-width: 200px; display: flex; align-items: center; gap: 9px; padding: 0 13px; border: 1px solid var(--line); border-radius: 11px; background: rgba(255,255,255,.02); }
.field input, .field select { width: 100%; padding: 12px 0; background: transparent; border: 0; outline: 0; color: var(--text); font: 13px Inter,sans-serif; }
.field select option { background: var(--panel); }
.seg { display: flex; border: 1px solid var(--line); border-radius: 11px; overflow: hidden; }
.seg button { border: 0; background: transparent; color: var(--muted); padding: 12px 13px; font-size: 12px; }
.seg button.on { background: rgba(16,185,129,.16); color: var(--bright); }
.mod-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; }
.mod-card { display: flex; gap: 12px; padding: 16px; border: 1px solid var(--line); border-radius: 15px; background: rgba(17,20,28,.8); transition: border-color .2s, transform .2s; }
.mod-card:hover { border-color: rgba(16,185,129,.4); transform: translateY(-3px); }
.mod-card img { width: 46px; height: 46px; border-radius: 10px; object-fit: cover; background: rgba(16,185,129,.1); }
.mod-card .body { min-width: 0; flex: 1; }
.mod-card h3 { margin: 0 0 5px; font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mod-card p { margin: 0 0 10px; color: var(--muted); font-size: 11px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mod-card .meta { display: flex; gap: 10px; color: #6b7280; font-size: 10px; margin-bottom: 10px; }
.mod-card a { display: inline-flex; align-items: center; gap: 5px; padding: 6px 10px; border-radius: 8px; background: rgba(16,185,129,.14); color: var(--bright); font-size: 11px; font-weight: 600; }
.mod-card a:hover { background: rgba(16,185,129,.25); }
.status-line { color: var(--muted); font-size: 12px; margin: 18px 0; }

.ai-layout { display: grid; grid-template-columns: 1.1fr .9fr; gap: 26px; align-items: start; }
.chat { border: 1px solid var(--line); border-radius: 18px; background: var(--panel); overflow: hidden; }
.chat-head { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.avatar { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; background: linear-gradient(135deg,var(--accent),var(--bright)); color: #04150f; font-weight: 900; }
.chat-head b { display: block; font-size: 14px; }
.chat-head small { color: var(--bright); font-size: 10px; }
.chat-body { padding: 22px; min-height: 300px; display: flex; flex-direction: column; gap: 14px; }
.msg { max-width: 84%; padding: 13px 16px; border-radius: 14px; font-size: 13px; line-height: 1.6; }
.msg.bot { background: rgba(16,185,129,.09); border: 1px solid rgba(16,185,129,.18); align-self: flex-start; }
.msg.user { background: rgba(255,255,255,.05); align-self: flex-end; }
.chat-input { display: flex; gap: 10px; padding: 14px; border-top: 1px solid var(--line); }
.chat-input input { flex: 1; padding: 12px 14px; border-radius: 11px; border: 1px solid var(--line); background: rgba(255,255,255,.02); color: var(--muted); outline: 0; }
.chat-input button { opacity: .45; cursor: not-allowed; }
.future { display: flex; flex-direction: column; gap: 12px; }
.future-item { display: flex; gap: 14px; padding: 18px; border: 1px solid var(--line); border-radius: 15px; background: var(--panel); }
.future-item span { color: var(--bright); font-size: 20px; }
.future-item b { display: block; font-size: 13px; margin-bottom: 5px; }
.future-item p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.55; }

@media (max-width: 980px) {
  .mod-grid, .steps { grid-template-columns: 1fr; }
  .ai-layout { grid-template-columns: 1fr; }
  .local-download .big-btn { margin-left: 0; width: 100%; }
}

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; gap: 40px; }
  .hero-card { order: -1; }
  .window { transform: none; }
  .grid, .download-grid { grid-template-columns: 1fr; }
  .dev-layout { grid-template-columns: 1fr; }
  .nav { display: none; }
  .stats { grid-template-columns: repeat(2,1fr); }
  .footer-legal { align-items: flex-start; }
}
