:root {
  --bg: #07080f;
  --card: rgba(22, 25, 42, .62);
  --card-b: rgba(255, 255, 255, .08);
  --text: #e9ecff;
  --muted: #8d93b8;
  --a1: #7c5cff;
  --a2: #00d4ff;
  --a3: #ff4fd8;
  --ok: #2ee59d;
  --bad: #ff5c7a;
  --warn: #ffc857;
  --grad: linear-gradient(135deg, var(--a1), var(--a2));
  --r: 20px;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font: 15px/1.5 "Segoe UI", Inter, system-ui, sans-serif;
  overflow-x: hidden;
}
svg { fill: currentColor; }
button { font: inherit; color: inherit; cursor: pointer; }
.muted { color: var(--muted); }

/* ---------- фон ---------- */
#bg, #confetti { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; }
#bg { z-index: 0; }
#confetti { z-index: 100; }
.blob {
  position: fixed; border-radius: 50%; filter: blur(90px); opacity: .35; z-index: 0;
  animation: float 18s ease-in-out infinite alternate; pointer-events: none;
}
.b1 { width: 520px; height: 520px; background: var(--a1); top: -160px; left: -120px; }
.b2 { width: 460px; height: 460px; background: var(--a2); bottom: -180px; right: -100px; animation-delay: -6s; }
.b3 { width: 360px; height: 360px; background: var(--a3); top: 40%; left: 45%; opacity: .18; animation-delay: -12s; }
@keyframes float {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(80px, 60px) scale(1.15); }
  100% { transform: translate(-60px, 30px) scale(.9); }
}

/* ---------- сплэш ---------- */
#splash {
  position: fixed; inset: 0; z-index: 200; background: var(--bg);
  display: grid; place-content: center; justify-items: center; gap: 22px;
  transition: opacity .6s, visibility .6s;
}
#splash.hide { opacity: 0; visibility: hidden; }
.logo-big { display: flex; gap: 6px; font-size: 64px; font-weight: 800; letter-spacing: 2px; }
.logo-big span {
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: pop .7s cubic-bezier(.2, 1.6, .4, 1) both;
}
.logo-big span:nth-child(2) { animation-delay: .12s; }
.logo-big span:nth-child(3) { animation-delay: .24s; }
@keyframes pop { from { transform: translateY(30px) scale(.4); opacity: 0; } }
.splash-bar { width: 220px; height: 4px; border-radius: 4px; background: rgba(255,255,255,.08); overflow: hidden; }
.splash-bar i { display: block; height: 100%; width: 40%; background: var(--grad); border-radius: 4px; animation: slide 1.1s ease-in-out infinite; }
@keyframes slide { from { transform: translateX(-100%); } to { transform: translateX(260%); } }
.splash-text { color: var(--muted); font-size: 13px; }

/* ---------- шапка ---------- */
.top {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 24px; padding: 14px 28px;
  background: rgba(7, 8, 15, .55); backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--card-b);
}
.brand { display: flex; align-items: center; gap: 12px; font-size: 18px; }
.brand span { color: var(--muted); font-weight: 400; }
.logo {
  width: 38px; height: 38px; border-radius: 12px; background: var(--grad);
  display: grid; place-items: center; box-shadow: 0 6px 24px rgba(124, 92, 255, .5);
}
.logo svg { width: 20px; height: 20px; fill: #fff; }
.tabs { position: relative; display: flex; gap: 4px; margin: 0 auto; padding: 4px; border-radius: 14px; background: rgba(255,255,255,.04); border: 1px solid var(--card-b); }
.tab { position: relative; z-index: 1; padding: 8px 18px; border: 0; background: none; border-radius: 10px; color: var(--muted); transition: color .3s; }
.tab.active { color: #fff; }
.tab-ink { position: absolute; top: 4px; bottom: 4px; border-radius: 10px; background: var(--grad); transition: left .4s cubic-bezier(.3, 1.4, .5, 1), width .4s; box-shadow: 0 4px 18px rgba(124, 92, 255, .45); }
.adb-pill { display: flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 99px; background: rgba(255,255,255,.05); border: 1px solid var(--card-b); font-size: 13px; color: var(--muted); }
.adb-pill i { width: 8px; height: 8px; border-radius: 50%; background: var(--warn); box-shadow: 0 0 0 0 currentColor; }
.adb-pill.ok i { background: var(--ok); animation: ping 2s infinite; color: var(--ok); }
.adb-pill.bad i { background: var(--bad); }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(46,229,157,.6); } 100% { box-shadow: 0 0 0 10px rgba(46,229,157,0); } }

/* ---------- раскладка ---------- */
.layout { position: relative; z-index: 1; display: grid; grid-template-columns: 340px 1fr; gap: 22px; padding: 26px 28px 60px; max-width: 1400px; margin: 0 auto; }
@media (max-width: 900px) { .layout { grid-template-columns: 1fr; } .devices { position: static; } .tabs { margin: 0; } .top { flex-wrap: wrap; } }
.card {
  background: var(--card); border: 1px solid var(--card-b); border-radius: var(--r);
  padding: 20px; backdrop-filter: blur(20px); margin-bottom: 22px;
  box-shadow: 0 20px 60px rgba(0,0,0,.35);
  animation: rise .6s cubic-bezier(.2, .9, .3, 1) both;
}
.panel .card:nth-child(2) { animation-delay: .08s; }
.panel .card:nth-child(3) { animation-delay: .16s; }
@keyframes rise { from { opacity: 0; transform: translateY(24px) scale(.98); } }
.devices { align-self: start; position: sticky; top: 90px; }
.card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.card-head h2 { margin: 0; font-size: 17px; font-weight: 600; display: flex; align-items: center; gap: 10px; }
.card-head h2 em { font-style: normal; width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: var(--grad); font-size: 13px; }
.panel { display: none; }
.panel.active { display: block; animation: fadeIn .45s ease both; }
@keyframes fadeIn { from { opacity: 0; transform: translateX(16px); } }

.icon-btn { width: 34px; height: 34px; border-radius: 10px; border: 1px solid var(--card-b); background: rgba(255,255,255,.04); display: grid; place-items: center; transition: .2s; }
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn:hover { background: rgba(255,255,255,.1); }
.icon-btn.spin svg { animation: rot .8s linear; }
@keyframes rot { to { transform: rotate(360deg); } }
.ghost-btn { border: 1px solid var(--card-b); background: rgba(255,255,255,.04); padding: 7px 14px; border-radius: 10px; }
.ghost-btn:hover { background: rgba(255,255,255,.1); }

/* ---------- устройства ---------- */
.scanner { text-align: center; padding: 10px 6px 4px; }
.scanner[hidden] { display: none; }
.radar { position: relative; width: 170px; height: 170px; margin: 6px auto 18px; display: grid; place-items: center; }
.radar > span { position: absolute; inset: 0; border-radius: 50%; border: 1px solid rgba(0, 212, 255, .35); animation: wave 3s ease-out infinite; }
.radar > span:nth-child(2) { animation-delay: 1s; }
.radar > span:nth-child(3) { animation-delay: 2s; }
@keyframes wave { from { transform: scale(.25); opacity: 1; } to { transform: scale(1); opacity: 0; } }
.radar .sweep { position: absolute; inset: 8px; border-radius: 50%; background: conic-gradient(from 0deg, rgba(0,212,255,.35), transparent 25%); animation: rot 2.4s linear infinite; }
.radar svg { position: relative; width: 44px; height: 44px; color: var(--a2); filter: drop-shadow(0 0 12px var(--a2)); }
.scan-title { font-weight: 600; margin: 0 0 6px; }
.scanner .muted { font-size: 13px; margin: 0; }

.device {
  position: relative; display: grid; grid-template-columns: 76px 1fr; gap: 14px; padding: 14px;
  border-radius: 16px; border: 1px solid var(--card-b); background: rgba(255,255,255,.03);
  margin-bottom: 12px; cursor: pointer; transition: border-color .3s, transform .3s, background .3s;
  animation: devIn .7s cubic-bezier(.2, 1.4, .4, 1) both;
}
@keyframes devIn { from { opacity: 0; transform: translateY(-20px) scale(.9); filter: blur(6px); } }
.device:hover { transform: translateY(-2px); }
.device.selected { border-color: rgba(0, 212, 255, .6); background: rgba(0, 212, 255, .06); box-shadow: 0 0 0 4px rgba(0, 212, 255, .08); }
.device.gone { animation: devOut .5s ease forwards; }
@keyframes devOut { to { opacity: 0; transform: translateX(-30px) scale(.9); filter: blur(4px); } }
.phone {
  width: 76px; height: 138px; border-radius: 16px; padding: 5px; background: #12141f;
  border: 2px solid #2a2e45; position: relative; box-shadow: 0 10px 30px rgba(0,0,0,.5);
}
.phone::before { content: ""; position: absolute; top: 7px; left: 50%; width: 18px; height: 4px; margin-left: -9px; border-radius: 4px; background: #2a2e45; z-index: 2; }
.phone .scr { width: 100%; height: 100%; border-radius: 11px; overflow: hidden; background: linear-gradient(160deg, #241f55, #0a3550); display: grid; place-items: center; position: relative; }
.phone .scr img { width: 100%; height: 100%; object-fit: cover; animation: fadeIn .5s; }
.phone .scr .glow { position: absolute; inset: 0; background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,.18) 50%, transparent 70%); animation: glare 3.5s infinite; }
@keyframes glare { from { transform: translateX(-120%); } to { transform: translateX(120%); } }
.dev-name { font-weight: 600; font-size: 16px; line-height: 1.25; }
.dev-brand { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: 1px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.chip { font-size: 11px; padding: 3px 8px; border-radius: 99px; background: rgba(255,255,255,.06); border: 1px solid var(--card-b); }
.chip.ok { color: var(--ok); border-color: rgba(46,229,157,.3); }
.chip.bad { color: var(--bad); border-color: rgba(255,92,122,.3); }
.chip.warn { color: var(--warn); border-color: rgba(255,200,87,.3); }
.meter { height: 6px; border-radius: 6px; background: rgba(255,255,255,.07); overflow: hidden; margin-top: 4px; }
.meter i { display: block; height: 100%; border-radius: 6px; background: var(--grad); width: 0; transition: width 1.2s cubic-bezier(.2,.9,.3,1); }
.meter-label { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin-top: 6px; }
.dev-actions { display: flex; gap: 6px; margin-top: 10px; }
.dev-actions button { font-size: 12px; padding: 5px 10px; border-radius: 8px; border: 1px solid var(--card-b); background: rgba(255,255,255,.05); }
.dev-actions button:hover { background: rgba(255,255,255,.12); }
.charging { color: var(--ok); animation: blink 1.4s infinite; }
@keyframes blink { 50% { opacity: .35; } }

/* ---------- APK ---------- */
.drop {
  display: grid; place-items: center; gap: 8px; padding: 28px; text-align: center; cursor: pointer;
  border: 2px dashed rgba(124, 92, 255, .4); border-radius: 16px; background: rgba(124, 92, 255, .04);
  transition: .3s; position: relative; overflow: hidden; color: var(--muted);
}
.drop b { color: var(--text); }
.drop:hover, .drop.over { border-color: var(--a2); background: rgba(0, 212, 255, .08); transform: scale(1.01); }
.drop.over .drop-icon { transform: translateY(-6px) scale(1.15); }
.drop-icon { width: 54px; height: 54px; border-radius: 16px; background: var(--grad); display: grid; place-items: center; transition: transform .35s cubic-bezier(.2,1.6,.4,1); animation: bob 3s ease-in-out infinite; }
.drop-icon svg { width: 28px; height: 28px; fill: #fff; }
@keyframes bob { 50% { transform: translateY(-5px); } }
.upload-progress:empty { display: none; }
.upload-progress { width: 100%; max-width: 420px; }
.up-item { font-size: 12px; text-align: left; margin-top: 6px; }
.up-item .progress { height: 6px; margin-top: 4px; }

.apk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; margin-top: 16px; }
.apk {
  position: relative; display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 14px;
  border: 1px solid var(--card-b); background: rgba(255,255,255,.03); cursor: pointer;
  transition: .25s; animation: rise .5s both;
}
.apk:hover { transform: translateY(-3px); border-color: rgba(255,255,255,.2); }
.apk.selected { border-color: var(--a1); background: rgba(124, 92, 255, .12); box-shadow: 0 8px 30px rgba(124, 92, 255, .25); }
.apk.selected::after { content: "✓"; position: absolute; top: -8px; right: -8px; width: 22px; height: 22px; border-radius: 50%; background: var(--grad); display: grid; place-items: center; font-size: 12px; animation: pop .4s cubic-bezier(.2,1.6,.4,1); }
.apk-ico { flex: none; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-weight: 700; font-size: 18px; overflow: hidden; }
.apk-ico img { width: 100%; height: 100%; object-fit: cover; }
.apk-name { font-size: 13px; font-weight: 600; word-break: break-all; line-height: 1.3; }
.apk-size { font-size: 11px; color: var(--muted); }
.apk .del { position: absolute; top: 6px; right: 6px; border: 0; background: none; color: var(--muted); opacity: 0; transition: .2s; font-size: 14px; }
.apk:hover .del { opacity: 1; }
.apk .del:hover { color: var(--bad); }

/* ---------- метод ---------- */
.method-row { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.select-wrap { flex: 1; min-width: 260px; position: relative; }
.select-wrap::after { content: "▾"; position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
select {
  width: 100%; appearance: none; padding: 12px 36px 12px 14px; border-radius: 12px; font: inherit; color: var(--text);
  background: rgba(255,255,255,.05); border: 1px solid var(--card-b); outline: none; transition: .2s;
}
select:focus { border-color: var(--a1); box-shadow: 0 0 0 4px rgba(124, 92, 255, .2); }
select option { background: #151827; }
.switch { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--muted); cursor: pointer; user-select: none; }
.switch input { display: none; }
.switch span { width: 40px; height: 22px; border-radius: 22px; background: rgba(255,255,255,.12); position: relative; transition: .3s; }
.switch span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: .3s cubic-bezier(.3,1.5,.5,1); }
.switch input:checked + span { background: var(--grad); }
.switch input:checked + span::after { left: 21px; }

.big-btn {
  position: relative; overflow: hidden; width: 100%; margin-top: 18px; padding: 16px; border: 0; border-radius: 14px;
  background: var(--grad); color: #fff; font-size: 16px; font-weight: 600; display: flex; justify-content: center; align-items: center; gap: 10px;
  box-shadow: 0 10px 30px rgba(124, 92, 255, .45); transition: transform .2s, box-shadow .2s, filter .3s;
}
.big-btn:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 14px 40px rgba(0, 212, 255, .45); }
.big-btn:active:not(:disabled) { transform: scale(.98); }
.big-btn:disabled { filter: grayscale(.8) brightness(.6); cursor: not-allowed; box-shadow: none; }
.btn-ico { width: 20px; height: 20px; }
.shine { position: absolute; inset: 0; background: linear-gradient(110deg, transparent 35%, rgba(255,255,255,.35) 50%, transparent 65%); animation: glare 2.8s infinite; }
.big-btn:disabled .shine { display: none; }
.big-btn.busy .btn-ico { animation: bob 1s infinite; }

/* ---------- выполнение ---------- */
.run-top { display: flex; gap: 24px; align-items: center; flex-wrap: wrap; }
.run-anim { display: flex; align-items: center; gap: 4px; }
.pkg { width: 58px; height: 58px; border-radius: 16px; background: var(--grad); display: grid; place-items: center; overflow: hidden; font-weight: 800; font-size: 24px; animation: bob 1.6s ease-in-out infinite; box-shadow: 0 8px 30px rgba(124,92,255,.5); }
.pkg img { width: 100%; height: 100%; object-fit: cover; }
.pkg img[src=""], .pkg img:not([src]) { display: none; }
.beam { display: flex; gap: 6px; padding: 0 8px; }
.beam i { width: 7px; height: 7px; border-radius: 50%; background: var(--a2); opacity: .15; animation: beam 1.2s infinite; }
.beam i:nth-child(2) { animation-delay: .15s; } .beam i:nth-child(3) { animation-delay: .3s; }
.beam i:nth-child(4) { animation-delay: .45s; } .beam i:nth-child(5) { animation-delay: .6s; }
@keyframes beam { 30% { opacity: 1; transform: scale(1.5); box-shadow: 0 0 10px var(--a2); } }
.phone-mini { width: 54px; height: 96px; border-radius: 12px; border: 2px solid #2f3450; padding: 4px; background: #111321; }
.phone-mini .screen { width: 100%; height: 100%; border-radius: 8px; background: #181b2e; display: grid; place-items: center; position: relative; overflow: hidden; }
.ring { width: 26px; height: 26px; border-radius: 50%; border: 3px solid rgba(255,255,255,.1); border-top-color: var(--a2); animation: rot .8s linear infinite; }
.check, .cross { position: absolute; width: 36px; height: 36px; fill: none; stroke-width: 5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 60; stroke-dashoffset: 60; }
.check { stroke: var(--ok); }
.cross { stroke: var(--bad); }
.run-anim.ok .ring, .run-anim.fail .ring { display: none; }
.run-anim.ok .beam, .run-anim.fail .beam { opacity: .2; }
.run-anim.ok .beam i, .run-anim.fail .beam i { animation: none; }
.run-anim.ok .pkg, .run-anim.fail .pkg { animation: none; }
.run-anim.ok .check { animation: draw .6s .1s ease forwards; }
.run-anim.ok .screen { background: rgba(46,229,157,.15); }
.run-anim.fail .cross { animation: draw .5s .1s ease forwards; }
.run-anim.fail .screen { background: rgba(255,92,122,.12); }
.run-anim.fail .phone-mini { animation: shake .5s; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.run-info { flex: 1; min-width: 240px; }
.run-title { font-weight: 600; font-size: 16px; }
.run-step { color: var(--muted); font-size: 13px; margin: 4px 0 10px; min-height: 20px; }
.run-step.swap { animation: fadeIn .35s; }
.progress { height: 10px; border-radius: 10px; background: rgba(255,255,255,.07); overflow: hidden; position: relative; }
.progress i { display: block; height: 100%; width: 0; border-radius: 10px; background: linear-gradient(90deg, var(--a1), var(--a2), var(--a3), var(--a1)); background-size: 300% 100%; animation: flow 2s linear infinite; transition: width .6s cubic-bezier(.2,.9,.3,1); }
.progress.ok i { background: var(--ok); }
.progress.fail i { background: var(--bad); }
@keyframes flow { to { background-position: 300% 0; } }
.run-meta { display: flex; justify-content: space-between; color: var(--muted); font-size: 12px; margin-top: 6px; }

.timeline { margin: 18px 0 6px; display: flex; flex-direction: column; gap: 2px; max-height: 260px; overflow: auto; }
.tl { display: flex; align-items: center; gap: 10px; font-size: 13px; padding: 6px 10px; border-radius: 10px; animation: tlIn .4s cubic-bezier(.2,1.2,.4,1) both; }
@keyframes tlIn { from { opacity: 0; transform: translateX(-14px); } }
.tl .dot { width: 18px; height: 18px; flex: none; border-radius: 50%; display: grid; place-items: center; font-size: 11px; border: 2px solid var(--a2); }
.tl.run .dot { border-color: rgba(255,255,255,.15); border-top-color: var(--a2); animation: rot .8s linear infinite; }
.tl.ok .dot { background: var(--ok); border-color: var(--ok); color: #04150d; }
.tl.fail .dot { border-color: var(--bad); color: var(--bad); }
.tl.head { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .6px; padding-top: 10px; }
.tl.head .dot { width: 8px; height: 8px; border: 0; background: var(--a1); margin: 0 5px; }
.tl.run { background: rgba(0, 212, 255, .06); }

.console-wrap summary { cursor: pointer; color: var(--muted); font-size: 13px; padding: 8px 0; }
.console {
  margin: 0; max-height: 320px; overflow: auto; padding: 14px; border-radius: 12px;
  background: rgba(0,0,0,.45); border: 1px solid var(--card-b);
  font: 12px/1.55 "Cascadia Code", Consolas, monospace; color: #b9c0e6; white-space: pre-wrap; word-break: break-word;
}
.console.tall { max-height: 70vh; }
.console .h { color: var(--a2); font-weight: 600; display: block; margin-top: 8px; }
.console .e0 { color: var(--ok); }
.console .e1 { color: var(--bad); }
.console .ln { display: block; animation: lnIn .25s ease both; }
@keyframes lnIn { from { opacity: 0; transform: translateY(4px); } }

/* ---------- инструменты ---------- */
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.tool {
  text-align: left; padding: 18px; border-radius: 16px; border: 1px solid var(--card-b); background: rgba(255,255,255,.03);
  transition: .25s; animation: rise .5s both;
}
.tool:hover { transform: translateY(-4px); border-color: rgba(0,212,255,.4); box-shadow: 0 12px 30px rgba(0, 212, 255, .15); }
.tool .ti { width: 40px; height: 40px; border-radius: 12px; background: var(--grad); display: grid; place-items: center; font-size: 20px; margin-bottom: 12px; }
.tool b { display: block; margin-bottom: 4px; }
.tool span { font-size: 12px; color: var(--muted); }
.dots { display: flex; gap: 5px; }
.dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--a2); animation: beam 1s infinite; }
.dots i:nth-child(2) { animation-delay: .15s; } .dots i:nth-child(3) { animation-delay: .3s; }
.dots.off { visibility: hidden; }

/* ---------- тосты ---------- */
#toasts { position: fixed; right: 22px; bottom: 22px; z-index: 150; display: flex; flex-direction: column; gap: 10px; }
.toast {
  min-width: 260px; max-width: 380px; padding: 12px 16px; border-radius: 14px; background: rgba(22, 25, 42, .92);
  border: 1px solid var(--card-b); backdrop-filter: blur(14px); box-shadow: 0 14px 40px rgba(0,0,0,.45);
  display: flex; gap: 10px; align-items: center; font-size: 14px;
  animation: toastIn .5s cubic-bezier(.2,1.4,.4,1) both;
}
.toast.out { animation: toastOut .35s ease forwards; }
.toast::before { content: ""; width: 4px; align-self: stretch; border-radius: 4px; background: var(--a2); }
.toast.ok::before { background: var(--ok); }
.toast.bad::before { background: var(--bad); }
@keyframes toastIn { from { opacity: 0; transform: translateX(60px) scale(.9); } }
@keyframes toastOut { to { opacity: 0; transform: translateX(60px); } }

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,.12); border-radius: 8px; }

/* ---------- системные приложения ---------- */
.small { font-size: 12px; font-weight: 400; }
.switch-row { display: flex; flex-wrap: wrap; gap: 10px 22px; margin-top: 14px; }
.hint {
  margin-top: 14px; padding: 12px 14px; border-radius: 12px; font-size: 13px;
  background: rgba(255, 200, 87, .08); border: 1px solid rgba(255, 200, 87, .3); color: #f3dca6;
  animation: fadeIn .4s ease both;
}
.hint code { background: rgba(0,0,0,.35); padding: 1px 6px; border-radius: 6px; font-size: 12px; }
.sys-list { display: flex; flex-direction: column; gap: 10px; }
.sys-empty { color: var(--muted); font-size: 13px; padding: 6px 0 4px; }
.sys-item {
  display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 14px;
  border: 1px solid var(--card-b); background: rgba(255,255,255,.03); animation: rise .45s both;
}
.sys-item .si { width: 40px; height: 40px; border-radius: 12px; background: linear-gradient(135deg, #ffc857, #ff4fd8); display: grid; place-items: center; font-size: 18px; flex: none; }
.sys-item .meta { flex: 1; min-width: 0; }
.sys-item .meta b { display: block; }
.sys-item .meta span { color: var(--muted); font-size: 12px; word-break: break-all; }
.sys-item.removing { animation: devOut .5s ease forwards; }
.sys-manual { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-top: 16px; }
.sys-manual input {
  flex: 1; min-width: 200px; padding: 10px 14px; border-radius: 12px; font: inherit; color: var(--text);
  background: rgba(255,255,255,.05); border: 1px solid var(--card-b); outline: none;
}
.sys-manual input:focus { border-color: var(--a1); box-shadow: 0 0 0 4px rgba(124, 92, 255, .2); }
.danger-btn {
  border: 1px solid rgba(255, 92, 122, .45); background: rgba(255, 92, 122, .12); color: #ffb3c1;
  padding: 9px 14px; border-radius: 12px; transition: .2s;
}
.danger-btn:hover { background: rgba(255, 92, 122, .25); transform: translateY(-1px); }

/* ---------- переключатель режима ---------- */
.mode-switch { display: flex; gap: 2px; padding: 3px; border-radius: 12px; background: rgba(255,255,255,.04); border: 1px solid var(--card-b); }
.mode-switch button { border: 0; background: none; color: var(--muted); padding: 6px 12px; border-radius: 9px; font-size: 13px; transition: .25s; }
.mode-switch button.active { background: rgba(255,255,255,.1); color: #fff; box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); }
.mode-switch button:hover:not(.active) { color: var(--text); }
.head-btns { display: flex; gap: 8px; }
.drop-sub { color: var(--muted); }
.drop-sub:empty { display: none; }

/* ---------- экран «Подключите USB» ---------- */
.connect-hero {
  display: grid; grid-template-columns: minmax(260px, 380px) 1fr; gap: 28px; align-items: center;
  overflow: hidden; max-height: 900px; position: relative;
  transition: max-height .7s cubic-bezier(.4,0,.2,1), opacity .5s, padding .6s, margin .6s, transform .6s;
  background: radial-gradient(120% 140% at 0% 0%, rgba(124,92,255,.22), transparent 55%), radial-gradient(120% 140% at 100% 100%, rgba(0,212,255,.14), transparent 55%), var(--card);
}
.connect-hero.collapsed { max-height: 0; opacity: 0; padding-top: 0; padding-bottom: 0; margin-bottom: 0; border-width: 0; transform: scale(.97); }
@media (max-width: 1100px) { .connect-hero { grid-template-columns: 1fr; } }
.hero-text h1 { margin: 0 0 14px; font-size: 26px; line-height: 1.2; background: linear-gradient(90deg, #fff, #b9c3ff); -webkit-background-clip: text; background-clip: text; color: transparent; }
.steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.steps li { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: 12px; border: 1px solid transparent; transition: .3s; animation: tlIn .45s both; }
.steps li b { display: block; font-size: 14px; }
.steps li span { color: var(--muted); font-size: 12.5px; }
.steps li code { display: inline-block; margin-top: 4px; background: rgba(0,0,0,.4); padding: 3px 8px; border-radius: 6px; color: #b9f3ff; font-size: 12px; user-select: all; }
.steps .num { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 700; border: 2px solid rgba(255,255,255,.15); color: var(--muted); margin-top: 1px; }
.steps li.done .num { background: var(--ok); border-color: var(--ok); color: #04150d; }
.steps li.done { opacity: .65; }
.steps li.now { background: rgba(0,212,255,.07); border-color: rgba(0,212,255,.3); }
.steps li.now .num { border-color: var(--a2); color: var(--a2); animation: ping2 1.6s infinite; }
@keyframes ping2 { 0% { box-shadow: 0 0 0 0 rgba(0,212,255,.5); } 100% { box-shadow: 0 0 0 10px rgba(0,212,255,0); } }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.hero-actions:empty { display: none; }
.connect-btn { width: auto; margin-top: 0; padding: 14px 26px; }
.hero-note { margin: 14px 0 0; font-size: 13px; color: var(--muted); }
.hero-note code { background: rgba(0,0,0,.4); padding: 2px 7px; border-radius: 6px; color: #ffd98a; user-select: all; }

/* иллюстрация: компьютер — кабель — телефон */
.plug-anim { position: relative; height: 230px; display: flex; align-items: center; justify-content: center; gap: 0; }
.pc { position: relative; width: 110px; }
.pc-scr { height: 72px; border-radius: 10px; border: 3px solid #2f3450; background: linear-gradient(160deg, #1b1f3a, #11283a); padding: 12px 10px; display: flex; flex-direction: column; gap: 6px; }
.pc-scr span { height: 5px; border-radius: 4px; background: rgba(124,92,255,.5); animation: blink 2s infinite; }
.pc-scr span:nth-child(2) { width: 70%; background: rgba(0,212,255,.5); animation-delay: .3s; }
.pc-scr span:nth-child(3) { width: 45%; animation-delay: .6s; }
.pc-base { width: 130px; height: 8px; margin: 2px -10px 0; border-radius: 0 0 8px 8px; background: #2f3450; }
.cable { position: relative; width: 120px; height: 40px; margin: 0 -4px; }
.cable svg { width: 100%; height: 100%; overflow: visible; }
.cable path { fill: none; stroke: #3a4066; stroke-width: 4; stroke-linecap: round; stroke-dasharray: 8 8; animation: dash 1.2s linear infinite; }
@keyframes dash { to { stroke-dashoffset: -32; } }
.cable .spark { position: absolute; top: 50%; left: 0; width: 10px; height: 10px; margin-top: -5px; border-radius: 50%; background: var(--a2); box-shadow: 0 0 14px 4px rgba(0,212,255,.7); animation: spark 1.8s ease-in-out infinite; opacity: 0; }
@keyframes spark { 0% { left: 0; opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { left: calc(100% - 10px); opacity: 0; } }
.ph-big { position: relative; width: 104px; height: 196px; border-radius: 22px; border: 3px solid #2f3450; background: #0e1020; padding: 7px; box-shadow: 0 20px 50px rgba(0,0,0,.5), 0 0 0 1px rgba(255,255,255,.04); animation: bob 3.2s ease-in-out infinite; }
.ph-notch { position: absolute; top: 9px; left: 50%; width: 30px; height: 5px; margin-left: -15px; border-radius: 5px; background: #2f3450; z-index: 2; }
.ph-screen { position: relative; height: 100%; border-radius: 15px; overflow: hidden; background: linear-gradient(170deg, #241f55, #0b3550); display: grid; place-items: center; }
.ph-usb { font-size: 30px; filter: drop-shadow(0 0 10px rgba(0,212,255,.8)); animation: blink 1.6s infinite; }
.ph-dialog {
  position: absolute; left: 6px; right: 6px; bottom: 10px; padding: 8px; border-radius: 10px; background: #f3f4fa; color: #1b1d2b;
  font-size: 8px; line-height: 1.3; display: flex; flex-direction: column; gap: 3px; transform: translateY(140%); transition: transform .6s cubic-bezier(.2,1.3,.4,1);
}
.ph-dialog b { font-size: 8.5px; }
.ph-dialog em { font-style: normal; align-self: flex-end; color: #3b5bff; font-weight: 700; padding: 2px 6px; border-radius: 6px; animation: tapHint 1.4s infinite; }
@keyframes tapHint { 50% { background: rgba(59,91,255,.18); } }
.plug-anim.auth .ph-dialog { transform: none; }
.plug-anim.auth .ph-usb { opacity: .15; }
.plug-anim.auth .ph-big { animation: shakeSoft 2.4s infinite; }
@keyframes shakeSoft { 0%, 90%, 100% { transform: rotate(0); } 92% { transform: rotate(-3deg); } 94% { transform: rotate(3deg); } 96% { transform: rotate(-2deg); } }
.plug-anim.busy .cable path { stroke: var(--a2); animation-duration: .5s; }
.plug-anim.busy .spark { animation-duration: .8s; }

/* полоса передачи файла */
.transfer { margin-top: 10px; font-size: 12px; color: var(--muted); }
.transfer span { display: block; margin-top: 4px; }
.progress.thin { height: 5px; }
