/* NeoTenet Revamp — lightweight glass UI */
:root{
  --bg:#07101f;--panel:rgba(10,17,31,.38);--panel-strong:rgba(12,20,38,.58);
  --line:rgba(255,255,255,.13);--text:#f8fbff;--muted:#aab6ca;--accent:#8b5cf6;--accent2:#22d3ee;
  --shadow:0 18px 55px rgba(0,0,0,.30);--radius:24px;--ease:cubic-bezier(.22,.8,.24,1)
}
html[data-theme="light"]{
  --bg:#eaf0f8;--panel:rgba(255,255,255,.30);--panel-strong:rgba(255,255,255,.48);
  --line:rgba(15,23,42,.11);--text:#101827;--muted:#5d6b80;--accent:#6d28d9;--accent2:#0891b2;
  --shadow:0 18px 45px rgba(31,41,55,.13)
}
html[data-theme="light"] body,html[data-theme="light"] body *{color:#000;text-shadow:0 0 2px #fff,0 0 5px #fff}
html[data-theme="light"] body .ui-svg,html[data-theme="light"] body svg{color:initial;text-shadow:none}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{margin:0;min-height:100vh;background:var(--bg);color:var(--text);font-family:Inter,"Segoe UI",Tahoma,Arial,sans-serif;line-height:1.45;overflow-x:hidden}html[dir="rtl"] body{font-family:"B Nazanin",B Nazanin,Tahoma,Arial,sans-serif}
button,input{font:inherit}
button,a{touch-action:manipulation}
button{color:inherit}
.bg-layer{position:fixed;inset:0;z-index:-3;background:url("/neotenet-assets/panel-bg.jpg") center center/cover no-repeat;transform:translateZ(0)}
.bg-scrim{position:fixed;inset:0;z-index:-2;background:linear-gradient(135deg,rgba(2,7,18,.25),rgba(6,13,29,.10) 52%,rgba(3,8,19,.28));backdrop-filter:saturate(1.08) contrast(1.02);-webkit-backdrop-filter:saturate(1.08) contrast(1.02)}
html[data-theme="light"] .bg-scrim{background:linear-gradient(135deg,rgba(238,244,252,.34),rgba(238,244,252,.18),rgba(225,235,247,.38))}
.panel-shell{width:min(1120px,calc(100% - 28px));margin:14px auto 34px}
.glass,.glass-inner{border:1px solid rgba(255,255,255,.16);background:var(--panel);box-shadow:var(--shadow),inset 0 1px 0 rgba(255,255,255,.10);backdrop-filter:blur(35px) saturate(135%);-webkit-backdrop-filter:blur(35px) saturate(135%)}
.glass{border-radius:var(--radius)}
.glass-inner{border-radius:20px;box-shadow:0 10px 30px rgba(0,0,0,.12)}
.topbar{min-height:76px;padding:11px 14px;display:flex;align-items:center;justify-content:space-between;gap:14px;position:sticky;top:10px;z-index:30}
.brand-lockup{display:flex;align-items:center;gap:12px;min-width:0}
.brand-logo{width:48px;height:48px;border-radius:15px;object-fit:cover;box-shadow:0 8px 24px rgba(124,58,237,.32)}
.brand-title{font-size:1.2rem;font-weight:850;letter-spacing:.2px}
.brand-subtitle{font-size:.76rem;color:var(--muted);margin-top:2px}
.top-actions{display:flex;align-items:center;gap:7px}
.icon-glass{width:43px;height:43px;border:1px solid var(--line);border-radius:14px;background:rgba(255,255,255,.07);display:inline-flex;align-items:center;justify-content:center;gap:5px;cursor:pointer;text-decoration:none;transition:transform .22s var(--ease),background .22s ease,border-color .22s ease}
.icon-glass:hover{transform:translateY(-2px);background:rgba(255,255,255,.13);border-color:rgba(255,255,255,.25)}
.mini-icon{font-size:1.05rem}
.hero{margin-top:14px;padding:27px;display:flex;align-items:center;justify-content:space-between;gap:24px;min-height:190px;overflow:hidden;position:relative}
.hero:after{content:"";position:absolute;width:260px;height:260px;border-radius:50%;background:radial-gradient(circle,rgba(139,92,246,.28),transparent 68%);inset:auto -90px -120px auto;pointer-events:none}
.hero-copy{max-width:720px}
.eyebrow{font-size:.72rem;font-weight:800;letter-spacing:1.5px;color:#c4b5fd}
.hero h1{font-size:clamp(1.55rem,3.5vw,2.65rem);line-height:1.15;margin:10px 0 9px}
.hero p{margin:0;color:var(--muted);max-width:650px}
.hero-badge{display:flex;align-items:center;gap:10px;padding:12px 15px;min-width:155px}
.status-dot{width:10px;height:10px;border-radius:50%;background:#34d399;box-shadow:0 0 0 5px rgba(52,211,153,.12),0 0 18px rgba(52,211,153,.6)}
.hero-badge strong,.hero-badge small{display:block}.hero-badge small{font-size:.72rem;color:var(--muted);max-width:120px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.stats-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:11px;margin-top:12px}
.stat{min-height:94px;padding:14px;display:flex;align-items:center;gap:12px}
.stat-icon,.quick-icon,.section-icon,.sub-icon{display:grid;place-items:center;flex:0 0 auto;border:1px solid rgba(255,255,255,.17);background:linear-gradient(145deg,rgba(255,255,255,.18),rgba(255,255,255,.055));box-shadow:inset 1px 1px 0 rgba(255,255,255,.18),0 10px 25px rgba(0,0,0,.18)}
.stat-icon{width:46px;height:46px;border-radius:15px;font-size:1.25rem}
.stat small,.stat strong{display:block}.stat small{font-size:.68rem;color:var(--muted);font-weight:700;letter-spacing:.7px}.stat strong{font-size:1rem;margin-top:2px;word-break:break-word}
.quick-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:11px;margin-top:12px}
.quick-card{border:1px solid var(--line);padding:13px 14px;border-radius:20px;background:var(--panel);box-shadow:var(--shadow);backdrop-filter:blur(35px);-webkit-backdrop-filter:blur(35px);display:flex;align-items:center;text-align:start;gap:12px;cursor:pointer;transition:transform .22s var(--ease),border-color .22s ease,background .22s ease}
.quick-card:hover{transform:translateY(-3px);border-color:rgba(167,139,250,.45);background:var(--panel-strong)}
.quick-card>span:nth-child(2){min-width:0;flex:1}.quick-card b,.quick-card small{display:block}.quick-card b{font-size:.92rem}.quick-card small{color:var(--muted);font-size:.71rem;margin-top:3px}.quick-card i{font-style:normal;opacity:.65;font-size:1.15rem}.quick-icon{width:43px;height:43px;border-radius:14px;color:#ddd6fe}
.accordion{margin-top:12px;overflow:hidden}
.accordion-trigger{width:100%;min-height:78px;padding:13px 16px;border:0;background:transparent;display:flex;align-items:center;gap:12px;text-align:start;cursor:pointer}
.section-icon{width:45px;height:45px;border-radius:15px;color:#ddd6fe;font-size:1.15rem}
.section-title{min-width:0;flex:1}.section-title b,.section-title small{display:block}.section-title b{font-size:1rem}.section-title small{font-size:.72rem;color:var(--muted);margin-top:2px}.chevron{font-size:1.5rem;opacity:.7;transition:transform .3s var(--ease)}.accordion.open .chevron{transform:rotate(180deg)}
.accordion-body{display:grid;grid-template-rows:0fr;transition:grid-template-rows .38s var(--ease);overflow:hidden}.accordion.open .accordion-body{grid-template-rows:1fr}.accordion-body>div{min-height:0;overflow:hidden}.subscription-grid{padding:0 14px 14px;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.sub-card{padding:13px}.sub-card.wide{grid-column:1/-1}.sub-top{display:flex;align-items:center;gap:10px;margin-bottom:11px}.sub-icon{width:39px;height:39px;border-radius:13px;font-weight:900;color:#c4b5fd}.sub-top b,.sub-top small{display:block}.sub-top b{font-size:.83rem}.sub-top small{font-size:.68rem;color:var(--muted);margin-top:2px}.copy-row{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:7px}.copy-row input{width:100%;min-width:0;height:40px;padding:0 10px;border:1px solid var(--line);border-radius:12px;background:rgba(0,0,0,.15);color:var(--muted);outline:none;font-size:.72rem;direction:ltr;text-overflow:ellipsis}.btn-main,.btn-icon{height:40px;border:1px solid var(--line);border-radius:12px;padding:0 13px;cursor:pointer;transition:transform .2s var(--ease),filter .2s ease}.btn-main{background:linear-gradient(135deg,var(--accent),#6d28d9);color:#fff;font-weight:800}.btn-icon{background:rgba(255,255,255,.07);min-width:48px}.btn-main:hover,.btn-icon:hover{transform:translateY(-2px);filter:brightness(1.08)}
.nodes-toolbar{padding:0 14px 10px;display:flex;justify-content:space-between;align-items:center;color:var(--muted);font-size:.72rem}.live-chip{display:inline-flex;align-items:center;gap:6px}.live-chip i{width:7px;height:7px;border-radius:50%;background:#34d399;box-shadow:0 0 12px #34d399}.nodes-grid{padding:0 14px 14px;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}.node-card{padding:13px}.node-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:9px}.node-title{font-size:.83rem;font-weight:800;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.node-type{font-size:.64rem;padding:4px 8px;border:1px solid var(--line);border-radius:999px;color:#d8d4fe;background:rgba(139,92,246,.12);white-space:nowrap}.node-copy{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:7px}.node-copy input{height:39px;width:100%;min-width:0;border:1px solid var(--line);border-radius:11px;background:rgba(0,0,0,.14);color:var(--muted);padding:0 9px;font-size:.7rem;direction:ltr;text-overflow:ellipsis}.empty-state{grid-column:1/-1;padding:28px;text-align:center;color:var(--muted)}
.footer-strip{margin-top:12px;padding:13px 15px;display:flex;align-items:center;justify-content:space-between;gap:12px;color:var(--muted);font-size:.7rem}.footer-strip span:first-child{color:var(--text);font-weight:850}.footer-strip a{color:#c4b5fd;text-decoration:none}
.drawer-backdrop{position:fixed;inset:0;background:rgba(0,0,0,.42);opacity:0;pointer-events:none;transition:opacity .3s ease;z-index:60}.drawer-backdrop.open{opacity:1;pointer-events:auto}.log-drawer{position:fixed;z-index:61;top:12px;bottom:12px;right:12px;width:min(720px,calc(100% - 24px));padding:14px;display:flex;flex-direction:column;transform:translateX(calc(100% + 30px));transition:transform .38s var(--ease)}html[dir="ltr"] .log-drawer{right:auto;left:12px;transform:translateX(calc(-100% - 30px))}.log-drawer.open{transform:translateX(0)}.drawer-head{display:flex;align-items:center;justify-content:space-between;gap:10px;padding-bottom:10px}.drawer-head b,.drawer-head small{display:block}.drawer-head small{font-size:.7rem;color:var(--muted);margin-top:2px}#logOutput{flex:1;min-height:0;margin:0;border:1px solid var(--line);border-radius:15px;background:rgba(0,0,0,.22);padding:12px;overflow:auto;direction:ltr;text-align:left;color:#cbd5e1;font:12px/1.55 ui-monospace,SFMono-Regular,Consolas,monospace;white-space:pre-wrap}.refresh-log{margin-top:10px}
.toast{position:fixed;left:50%;bottom:24px;z-index:100;transform:translate(-50%,20px);opacity:0;pointer-events:none;padding:10px 15px;border:1px solid var(--line);border-radius:13px;background:var(--panel-strong);box-shadow:var(--shadow);font-size:.78rem;transition:opacity .25s ease,transform .25s var(--ease)}.toast.show{opacity:1;transform:translate(-50%,0)}
.qr-modal{position:fixed;inset:0;display:grid;place-items:center;padding:18px;background:rgba(0,0,0,.55);opacity:0;pointer-events:none;transition:opacity .25s ease;z-index:90}.qr-modal.open{opacity:1;pointer-events:auto}.qr-card{width:min(330px,100%);padding:20px;text-align:center;position:relative}.qr-close{position:absolute;top:9px;right:9px}.qr-card #qrcodeWrapper{padding:18px 0 12px}.qr-card img{max-width:220px;width:100%;height:auto;border-radius:10px;background:#fff;padding:7px}.qr-card small{color:var(--muted)}
@media (max-width:820px){.stats-grid{grid-template-columns:repeat(2,1fr)}.quick-grid{grid-template-columns:1fr}.hero{align-items:flex-start;flex-direction:column}.hero-badge{min-width:0;width:100%}.subscription-grid,.nodes-grid{grid-template-columns:1fr}.sub-card.wide{grid-column:auto}}
@media (max-width:560px){
  .panel-shell{width:calc(100% - 14px);margin:7px auto 20px}
  .topbar{top:5px;min-height:64px;padding:8px 9px;border-radius:19px}.brand-logo{width:42px;height:42px;border-radius:13px}.brand-title{font-size:1rem}.brand-subtitle{font-size:.64rem}
  .top-actions{gap:5px}.icon-glass{width:38px;height:38px;border-radius:12px;font-size:.72rem}.mini-icon{font-size:.9rem}
  .hero{margin-top:9px;padding:20px 16px;min-height:0;border-radius:20px}.hero h1{font-size:1.45rem}.hero p{font-size:.77rem}.eyebrow{font-size:.61rem}
  .stats-grid{gap:8px;margin-top:9px}.stat{min-height:82px;padding:11px 10px;gap:9px;border-radius:18px}.stat-icon{width:38px;height:38px;border-radius:12px;font-size:1rem}.stat small{font-size:.59rem}.stat strong{font-size:.84rem}
  .quick-card{padding:11px;border-radius:17px}.quick-icon{width:39px;height:39px;border-radius:12px}.quick-card b{font-size:.82rem}.quick-card small{font-size:.64rem}
  .accordion-trigger{min-height:72px;padding:11px}.section-icon{width:41px;height:41px;border-radius:13px}.section-title b{font-size:.87rem}.section-title small{font-size:.62rem}.subscription-grid,.nodes-grid{padding:0 9px 9px;gap:8px}.sub-card,.node-card{padding:10px;border-radius:16px}.sub-top b,.node-title{font-size:.74rem}.sub-top small{font-size:.61rem}.copy-row,.node-copy{grid-template-columns:minmax(0,1fr) auto}.copy-row input,.node-copy input{grid-column:1/-1;height:37px}.btn-main,.btn-icon{height:37px}.node-type{font-size:.57rem}.footer-strip{flex-wrap:wrap;padding:11px;font-size:.61rem}
}
@media (prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;transition-duration:.01ms!important;animation-duration:.01ms!important}}


/* NeoPanel JS visual layer — UI only */
.ui-svg{width:22px;height:22px;display:block;overflow:visible}
.stat-icon .ui-svg,.quick-icon .ui-svg,.section-icon .ui-svg,.sub-icon .ui-svg{width:23px;height:23px}
.control-icon .ui-svg{width:19px;height:19px}
.icon-glass .ui-svg{width:20px;height:20px}

.control-pill{height:43px;min-width:72px;padding:0 12px;border:1px solid rgba(255,255,255,.18);border-radius:15px;background:linear-gradient(145deg,rgba(255,255,255,.18),rgba(255,255,255,.055));box-shadow:inset 1px 1px 0 rgba(255,255,255,.18),0 9px 24px rgba(0,0,0,.22);display:inline-flex;align-items:center;justify-content:center;gap:7px;cursor:pointer;color:#fff;transition:transform .22s var(--ease),filter .22s ease,border-color .22s ease}
.control-pill:hover{transform:translateY(-2px);filter:brightness(1.08);border-color:rgba(255,255,255,.34)}
.theme-switch{width:76px;height:43px;padding:3px;border:1px solid rgba(255,255,255,.18);border-radius:999px;background:linear-gradient(145deg,rgba(255,255,255,.17),rgba(255,255,255,.055));box-shadow:inset 1px 1px 0 rgba(255,255,255,.16),0 9px 24px rgba(0,0,0,.22);cursor:pointer;position:relative;transition:transform .22s var(--ease),filter .22s ease}
.theme-switch:hover{transform:translateY(-2px);filter:brightness(1.08)}
.theme-track{position:relative;display:block;width:100%;height:100%;border-radius:999px;background:linear-gradient(90deg,rgba(34,211,238,.28),rgba(139,92,246,.38));box-shadow:inset 0 2px 5px rgba(0,0,0,.22)}
.theme-track:before,.theme-track:after{content:'';position:absolute;top:50%;transform:translateY(-50%);font-size:13px;opacity:.78}.theme-track:before{content:'☀';left:9px}.theme-track:after{content:'☾';right:9px}
.theme-thumb{position:absolute;top:3px;left:3px;width:29px;height:29px;border-radius:50%;display:grid;place-items:center;background:linear-gradient(145deg,#fff,#dbeafe 48%,#a78bfa);box-shadow:0 5px 13px rgba(0,0,0,.38),inset 1px 1px 0 rgba(255,255,255,.9);transition:transform .38s var(--ease)}
.theme-thumb .ui-svg{width:17px;height:17px}.theme-switch[data-state="light"] .theme-thumb{transform:translateX(37px)}

.icon-glass{box-shadow:inset 1px 1px 0 rgba(255,255,255,.16),0 9px 24px rgba(0,0,0,.20)}
.quick-icon,.stat-icon,.section-icon,.sub-icon{position:relative;overflow:hidden;background:linear-gradient(145deg,rgba(255,255,255,.23),rgba(255,255,255,.055));box-shadow:inset 1px 1px 0 rgba(255,255,255,.23),inset -2px -2px 6px rgba(0,0,0,.10),0 11px 26px rgba(0,0,0,.22);color:#fff}
.quick-icon:after,.stat-icon:after,.section-icon:after,.sub-icon:after{content:'';position:absolute;inset:2px;border-radius:inherit;border-top:1px solid rgba(255,255,255,.24);pointer-events:none}
.quick-icon .ui-svg,.stat-icon .ui-svg,.section-icon .ui-svg,.sub-icon .ui-svg{filter:drop-shadow(0 2px 2px rgba(0,0,0,.5))}
.quick-arrow{width:42px;height:42px;display:grid;place-items:center;border-radius:14px;background:linear-gradient(145deg,rgba(255,255,255,.22),rgba(255,255,255,.05));box-shadow:inset 1px 1px 0 rgba(255,255,255,.2),0 9px 22px rgba(0,0,0,.18);opacity:1!important}
.quick-arrow .ui-svg{width:21px;height:21px;color:#fff}

.chevron{width:43px;height:43px;display:grid;place-items:center;flex:0 0 auto;border-radius:14px;color:#fff;background:linear-gradient(145deg,rgba(255,255,255,.24),rgba(255,255,255,.06));border:1px solid rgba(255,255,255,.18);box-shadow:inset 1px 1px 0 rgba(255,255,255,.22),0 9px 22px rgba(0,0,0,.28);opacity:1;transition:transform .34s var(--ease),filter .22s ease,background .22s ease}
.chevron .ui-svg{width:24px;height:24px}.accordion.open .chevron{transform:rotate(180deg);background:linear-gradient(145deg,rgba(139,92,246,.46),rgba(34,211,238,.16));filter:brightness(1.08)}

/* Reliable collapsing: JS sets an exact max-height, so content always closes. */
.accordion-body{display:block;max-height:0;opacity:0;overflow:hidden;transition:max-height .42s var(--ease),opacity .22s ease;padding:0}
.accordion.open .accordion-body{max-height:0;opacity:1}
.accordion-body>div{min-height:0;overflow:visible}

.hero,.topbar,.stat,.quick-card,.accordion,.channel-card,.footer-strip{background:var(--panel)}
.hero{border-color:rgba(255,255,255,.17)}
.hero:after{background:radial-gradient(circle,rgba(139,92,246,.20),transparent 68%)}

.channel-card{margin-top:12px;padding:16px;display:flex;align-items:center;gap:14px;position:relative;overflow:hidden}
.channel-card:before{content:'';position:absolute;inset:auto -70px -100px auto;width:260px;height:220px;border-radius:50%;background:radial-gradient(circle,rgba(34,211,238,.18),transparent 68%);pointer-events:none}
.channel-mark{width:58px;height:58px;display:grid;place-items:center;flex:0 0 auto;border-radius:18px;background:linear-gradient(145deg,rgba(255,255,255,.24),rgba(139,92,246,.16));box-shadow:inset 1px 1px 0 rgba(255,255,255,.25),0 12px 28px rgba(0,0,0,.24)}
.channel-mark .ui-svg{width:32px;height:32px}
.channel-copy{min-width:0;flex:1}.channel-kicker{display:block;font-size:.62rem;font-weight:900;letter-spacing:1.2px;color:#c4b5fd}.channel-copy b{display:block;font-size:1.05rem;margin-top:2px}.channel-copy p{margin:4px 0 0;color:var(--muted);font-size:.72rem;max-width:760px}
.channel-button{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:43px;padding:0 14px;border:1px solid rgba(255,255,255,.17);border-radius:14px;background:linear-gradient(135deg,#7c3aed,#2563eb);color:#fff;text-decoration:none;font-weight:850;white-space:nowrap;box-shadow:0 10px 24px rgba(37,99,235,.22),inset 1px 1px 0 rgba(255,255,255,.22);transition:transform .22s var(--ease),filter .22s ease}
.channel-button:hover{transform:translateY(-2px);filter:brightness(1.08)}.channel-button .ui-svg{width:18px;height:18px}

@media (max-width:560px){
 .control-pill{height:38px;min-width:62px;padding:0 9px;border-radius:12px}.theme-switch{width:65px;height:38px}.theme-thumb{width:26px;height:26px}.theme-switch[data-state="light"] .theme-thumb{transform:translateX(30px)}
 .theme-track:before{left:8px}.theme-track:after{right:8px}.channel-card{align-items:flex-start;flex-wrap:wrap;padding:13px}.channel-mark{width:50px;height:50px;border-radius:15px}.channel-copy{width:calc(100% - 64px)}.channel-copy p{font-size:.66rem}.channel-button{width:100%;min-height:40px}.chevron{width:39px;height:39px}.quick-arrow{width:39px;height:39px}
}

/* NeoPanel JS — reference UI polish */
.theme-switch{width:142px;height:48px;padding:3px;border:1px solid rgba(255,255,255,.30);border-radius:999px;background:linear-gradient(145deg,rgba(255,255,255,.25),rgba(255,255,255,.07));box-shadow:inset 1px 1px 0 rgba(255,255,255,.42),inset -2px -2px 7px rgba(0,0,0,.18),0 12px 28px rgba(0,0,0,.28);position:relative;overflow:hidden;cursor:pointer;transition:transform .22s var(--ease),filter .22s ease}
.theme-switch:hover{transform:translateY(-2px);filter:brightness(1.07)}
.theme-track{position:relative;width:100%;height:100%;display:block;border-radius:999px;overflow:hidden;background:linear-gradient(100deg,rgba(248,250,252,.28),rgba(148,163,184,.20) 48%,rgba(15,23,42,.42));box-shadow:inset 0 2px 8px rgba(0,0,0,.24),inset 0 -1px 0 rgba(255,255,255,.12)}
.theme-side{position:absolute;inset-block:0;display:flex;align-items:center;gap:6px;font-size:10px;font-weight:900;letter-spacing:.65px;color:rgba(255,255,255,.82);text-shadow:0 1px 2px rgba(0,0,0,.45);pointer-events:none}
.theme-side-light{left:10px}.theme-side-dark{right:10px}
.theme-side-icon{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round;filter:drop-shadow(0 2px 2px rgba(0,0,0,.35))}
.theme-thumb{position:absolute;top:4px;left:4px;width:38px;height:38px;border-radius:50%;display:grid;place-items:center;background:linear-gradient(145deg,#ffffff 0%,#e8f0ff 52%,#a78bfa 100%);border:1px solid rgba(255,255,255,.68);box-shadow:inset 2px 2px 2px rgba(255,255,255,.88),inset -2px -2px 4px rgba(71,85,105,.20),0 7px 15px rgba(0,0,0,.34);transition:transform .42s cubic-bezier(.22,.8,.24,1)}
.theme-thumb .ui-svg{width:20px;height:20px;fill:none;stroke:#334155;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;filter:drop-shadow(0 1px 1px rgba(255,255,255,.65))}
.theme-switch[data-state="dark"] .theme-thumb{transform:translateX(92px)}
.theme-switch[data-state="light"] .theme-thumb{transform:translateX(0)}
.theme-switch[data-state="dark"] .theme-side-dark,.theme-switch[data-state="light"] .theme-side-light{color:#fff}
.control-pill,.icon-glass{background:linear-gradient(145deg,rgba(255,255,255,.22),rgba(255,255,255,.055));box-shadow:inset 1px 1px 0 rgba(255,255,255,.28),inset -2px -2px 5px rgba(0,0,0,.10),0 10px 25px rgba(0,0,0,.24)}
.control-icon .ui-svg,.icon-glass .ui-svg{filter:drop-shadow(0 2px 2px rgba(0,0,0,.5))}

/* The second reference is a clean outline icon language: keep every icon crisp and consistent. */
.ui-svg{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round}
.stat-icon,.quick-icon,.section-icon,.sub-icon,.quick-arrow,.chevron{color:#fff}
.stat-icon .ui-svg,.quick-icon .ui-svg,.section-icon .ui-svg,.sub-icon .ui-svg,.quick-arrow .ui-svg,.chevron .ui-svg{filter:drop-shadow(0 2px 2px rgba(0,0,0,.48))}
.section-icon,.quick-icon,.stat-icon,.sub-icon{background:linear-gradient(145deg,rgba(255,255,255,.25),rgba(255,255,255,.06));border-color:rgba(255,255,255,.24);box-shadow:inset 1px 1px 0 rgba(255,255,255,.30),inset -2px -2px 6px rgba(0,0,0,.12),0 12px 26px rgba(0,0,0,.25)}
.chevron{width:46px;height:46px;border-radius:15px;border:1px solid rgba(255,255,255,.25);background:linear-gradient(145deg,rgba(255,255,255,.28),rgba(255,255,255,.07));box-shadow:inset 1px 1px 0 rgba(255,255,255,.34),inset -2px -2px 5px rgba(0,0,0,.12),0 10px 24px rgba(0,0,0,.28);opacity:1}
.chevron .ui-svg{width:25px;height:25px;stroke-width:2.2}
.accordion.open .chevron{background:linear-gradient(145deg,rgba(139,92,246,.52),rgba(34,211,238,.18));filter:brightness(1.08);box-shadow:inset 1px 1px 0 rgba(255,255,255,.34),0 10px 26px rgba(139,92,246,.20)}

/* Reliable accordion animation: inline max-height from JS controls the real content height. */
.accordion-body{display:block;max-height:0;opacity:0;overflow:hidden;transition:max-height .42s var(--ease),opacity .22s ease;padding:0}
.accordion.open .accordion-body{opacity:1}
.accordion-body>div{min-height:0;overflow:visible}

.glass,.glass-inner{background:rgba(8,15,30,.28);border-color:rgba(255,255,255,.18);backdrop-filter:blur(35px) saturate(150%);-webkit-backdrop-filter:blur(35px) saturate(150%)}
html[data-theme="light"] .glass,html[data-theme="light"] .glass-inner{background:rgba(255,255,255,.27);border-color:rgba(255,255,255,.38)}
@media (max-width:560px){.theme-switch{width:112px;height:40px}.theme-thumb{width:32px;height:32px;top:3px;left:3px}.theme-switch[data-state="dark"] .theme-thumb{transform:translateX(72px)}.theme-side{font-size:8px;gap:4px}.theme-side-light{left:7px}.theme-side-dark{right:7px}.theme-side-icon{width:16px;height:16px}.control-pill{height:38px;min-width:62px}.chevron{width:40px;height:40px}.chevron .ui-svg{width:22px;height:22px}}

@media (max-width: 700px){.bg-layer{background-position:54% center;background-size:cover}.glass,.glass-inner{backdrop-filter:blur(7px) saturate(132%);-webkit-backdrop-filter:blur(7px) saturate(132%)}}


/* NeoTenet final UI polish: clearer background + stable icon-only theme switch */
.glass,.glass-inner{
  background:rgba(8,15,30,.16)!important;
  border-color:rgba(255,255,255,.16);
  backdrop-filter:blur(2px) saturate(122%)!important;
  -webkit-backdrop-filter:blur(2px) saturate(122%)!important;
}
html[data-theme="light"] .glass,html[data-theme="light"] .glass-inner{
  background:rgba(255,255,255,.16)!important;
  border-color:rgba(255,255,255,.28);
}

.control-pill,.icon-glass,.quick-arrow,.chevron{
  backdrop-filter:blur(2px) saturate(122%);
  -webkit-backdrop-filter:blur(2px) saturate(122%);
}

.theme-switch{
  width:86px!important;
  height:42px!important;
  padding:3px!important;
  border:1px solid rgba(255,255,255,.24)!important;
  border-radius:999px!important;
  background:rgba(255,255,255,.10)!important;
  box-shadow:inset 0 1px 2px rgba(255,255,255,.20),inset 0 -2px 5px rgba(0,0,0,.16),0 8px 20px rgba(0,0,0,.20)!important;
  overflow:hidden!important;
}
.theme-track{
  position:relative!important;
  width:100%!important;
  height:100%!important;
  border-radius:999px!important;
  overflow:hidden!important;
  background:rgba(15,23,42,.18)!important;
  box-shadow:inset 0 1px 5px rgba(0,0,0,.20)!important;
}
.theme-side{
  position:absolute!important;
  top:50%!important;
  bottom:auto!important;
  transform:translateY(-50%)!important;
  width:30px!important;
  height:30px!important;
  display:grid!important;
  place-items:center!important;
  gap:0!important;
  color:rgba(255,255,255,.82)!important;
  pointer-events:none!important;
}
.theme-side-moon{left:5px!important;right:auto!important}
.theme-side-sun{right:5px!important;left:auto!important}
.theme-side-icon{
  width:18px!important;
  height:18px!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.8!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
  filter:drop-shadow(0 1px 2px rgba(0,0,0,.35))!important;
}
.theme-thumb{
  position:absolute!important;
  top:3px!important;
  left:3px!important;
  width:34px!important;
  height:34px!important;
  border-radius:50%!important;
  display:grid!important;
  place-items:center!important;
  background:linear-gradient(145deg,#fff,#e8f0ff 55%,#c4b5fd)!important;
  border:1px solid rgba(255,255,255,.72)!important;
  box-shadow:inset 1px 1px 2px rgba(255,255,255,.9),inset -1px -1px 3px rgba(71,85,105,.16),0 5px 12px rgba(0,0,0,.30)!important;
  transition:transform .30s cubic-bezier(.22,.8,.24,1)!important;
  z-index:2!important;
}
.theme-thumb .ui-svg{
  width:18px!important;
  height:18px!important;
  fill:none!important;
  stroke:#334155!important;
  stroke-width:1.8!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
/* Dark = thumb on the moon side; Light = thumb on the sun side. */
.theme-switch[data-state="dark"] .theme-thumb{transform:translateX(0)!important}
.theme-switch[data-state="light"] .theme-thumb{transform:translateX(44px)!important}
.theme-switch[data-state="dark"] .theme-side-moon,
.theme-switch[data-state="light"] .theme-side-sun{color:#fff!important}
.theme-switch[data-state="dark"] .theme-side-sun,
.theme-switch[data-state="light"] .theme-side-moon{color:rgba(255,255,255,.48)!important}

@media (max-width:560px){
  .glass,.glass-inner{backdrop-filter:blur(1.5px) saturate(118%)!important;-webkit-backdrop-filter:blur(1.5px) saturate(118%)!important}
  .theme-switch{width:78px!important;height:38px!important}
  .theme-side{width:27px!important;height:27px!important}
  .theme-side-moon{left:4px!important}.theme-side-sun{right:4px!important}
  .theme-side-icon{width:16px!important;height:16px!important}
  .theme-thumb{width:30px!important;height:30px!important;top:3px!important;left:3px!important}
  .theme-switch[data-state="light"] .theme-thumb{transform:translateX(40px)!important}
}


/* NeoPanel — final theme switch alignment fix (UI only) */
.theme-switch{
  width:92px!important;
  height:46px!important;
  padding:3px!important;
  box-sizing:border-box!important;
  position:relative!important;
  overflow:hidden!important;
  display:block!important;
  flex:0 0 auto!important;
}
.theme-track{
  width:100%!important;
  height:100%!important;
  position:relative!important;
  display:block!important;
  box-sizing:border-box!important;
  overflow:hidden!important;
  border-radius:999px!important;
}
.theme-side{
  position:absolute!important;
  top:0!important;
  bottom:0!important;
  height:auto!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  pointer-events:none!important;
}
.theme-side-moon{left:7px!important;right:auto!important;width:28px!important}
.theme-side-sun{right:7px!important;left:auto!important;width:28px!important}
.theme-side-icon{width:18px!important;height:18px!important;display:block!important}
.theme-thumb{
  width:34px!important;
  height:34px!important;
  top:2px!important;
  left:2px!important;
  margin:0!important;
  box-sizing:border-box!important;
  display:grid!important;
  place-items:center!important;
  transform:translateX(0)!important;
  transition:transform .30s cubic-bezier(.22,.8,.24,1)!important;
}
.theme-thumb .ui-svg{width:18px!important;height:18px!important}
.theme-switch[data-state="light"] .theme-thumb{transform:translateX(44px)!important}
.theme-switch[data-state="dark"] .theme-thumb{transform:translateX(0)!important}

@media (max-width:560px){
  .theme-switch{width:80px!important;height:40px!important;padding:3px!important}
  .theme-side-moon{left:4px!important;width:24px!important}
  .theme-side-sun{right:4px!important;width:24px!important}
  .theme-side-icon{width:15px!important;height:15px!important}
  .theme-thumb{width:28px!important;height:28px!important;top:2px!important;left:2px!important}
  .theme-switch[data-state="light"] .theme-thumb{transform:translateX(40px)!important}
}


/* NeoPanel — requested theme switch cleanup + text readability */
.theme-track::before,.theme-track::after{display:none!important;content:none!important}
.theme-side-moon,.theme-side-sun{display:none!important}
.theme-thumb{left:50%!important;top:50%!important;transform:translate(-50%,-50%)!important}
.theme-switch[data-state="light"] .theme-thumb,.theme-switch[data-state="dark"] .theme-thumb{transform:translate(-50%,-50%)!important}
.theme-thumb .ui-svg{width:20px!important;height:20px!important;filter:drop-shadow(0 1px 1px rgba(0,0,0,.45))!important}
@media (max-width:560px){.theme-thumb{left:50%!important;top:50%!important;transform:translate(-50%,-50%)!important}.theme-switch[data-state="light"] .theme-thumb,.theme-switch[data-state="dark"] .theme-thumb{transform:translate(-50%,-50%)!important}}

/* White text: strong black depth/shadow for readability and a subtle 3D look. */
body .glass h1,body .glass h2,body .glass h3,body .glass h4,body .glass h5,body .glass h6,body .glass strong,body .glass b,body .glass label,body .glass button,body .glass a,body .glass span,body .glass p,body .glass small,body .glass input,body .glass textarea,body .glass select,body .topbar .brand-title,body .topbar .brand-subtitle{ text-shadow:0 1px 0 rgba(0,0,0,.92),0 2px 4px rgba(0,0,0,.72)!important }

/* Gray/muted text -> black as requested. */
:root{--muted:#000!important}
html[data-theme="light"]{--muted:#000!important}

/* Final theme-switch alignment: one clean thumb, vertically centered, no overflow. */
.theme-switch{overflow:hidden!important}
.theme-thumb{left:4px!important;right:auto!important;top:50%!important;transform:translateY(-50%)!important}
.theme-switch[data-state="dark"] .theme-thumb{left:4px!important;right:auto!important;transform:translateY(-50%)!important}
.theme-switch[data-state="light"] .theme-thumb{left:calc(100% - 42px)!important;right:auto!important;transform:translateY(-50%)!important}
@media (max-width:560px){
  .theme-thumb{left:3px!important;top:50%!important;transform:translateY(-50%)!important}
  .theme-switch[data-state="dark"] .theme-thumb{left:3px!important;transform:translateY(-50%)!important}
  .theme-switch[data-state="light"] .theme-thumb{left:calc(100% - 35px)!important;transform:translateY(-50%)!important}
}
/* FINAL CLEAN THEME PATCH — no side icons, centered thumb, sun icon. */
.theme-side-moon,.theme-side-sun{display:none!important}
.theme-track:before,.theme-track:after{content:none!important;display:none!important}
.theme-thumb .ui-svg{width:20px!important;height:20px!important;display:block!important}
@media (max-width:560px){.theme-thumb .ui-svg{width:18px!important;height:18px!important}}

/* FINAL REQUESTED UI PATCH — theme icon + text readability only. */
.theme-switch{
  width:92px!important;height:46px!important;padding:3px!important;
  overflow:hidden!important;position:relative!important;box-sizing:border-box!important;
}
.theme-track{
  width:100%!important;height:100%!important;position:relative!important;
  overflow:hidden!important;border-radius:999px!important;
}
.theme-side,.theme-side-moon,.theme-side-sun,
.theme-track:before,.theme-track:after{display:none!important;content:none!important}
.theme-thumb{
  position:absolute!important;left:50%!important;top:50%!important;
  width:34px!important;height:34px!important;margin:0!important;
  transform:translate(-50%,-50%)!important;
  display:grid!important;place-items:center!important;z-index:2!important;
}
.theme-switch[data-state="dark"] .theme-thumb,
.theme-switch[data-state="light"] .theme-thumb{
  left:50%!important;top:50%!important;transform:translate(-50%,-50%)!important;
}
.theme-thumb .ui-svg{
  width:20px!important;height:20px!important;display:block!important;
  stroke:#111827!important;fill:none!important;
  stroke-width:1.8!important;stroke-linecap:round!important;stroke-linejoin:round!important;
  filter:drop-shadow(0 1px 1px rgba(0,0,0,.50))!important;
}
/* White UI text gets a visible black depth/shadow. */
body :where(h1,h2,h3,h4,h5,h6,strong,b,button,a,label,.brand-title,.control-pill,.channel-button,.btn-main){
  text-shadow:0 1px 0 rgba(0,0,0,.95),0 2px 3px rgba(0,0,0,.78)!important;
}
/* All muted/gray interface text is explicitly black as requested. */
body :where(.brand-subtitle,.hero p,.hero-badge small,.stat small,.quick-card small,
.section-title small,.sub-top small,.copy-row input,.node-copy input,.empty-state,
.footer-strip,.drawer-head small,.qr-card small,.nodes-toolbar,.channel-copy p,
.sub-card small,.node-type){color:#000!important}
:root{--muted:#000!important}
html[data-theme="light"]{--muted:#000!important}
@media (max-width:560px){
  .theme-switch{width:80px!important;height:40px!important}
  .theme-thumb{width:30px!important;height:30px!important}
  .theme-thumb .ui-svg{width:18px!important;height:18px!important}
}

/* FINAL THEME READABILITY PATCH — preserve core logic, visual text only. */
html:not([data-theme="light"]) body :where(.brand-subtitle,.hero p,.hero-badge small,.stat small,.quick-card small,
.section-title small,.sub-top small,.copy-row input,.node-copy input,.empty-state,
.footer-strip,.drawer-head small,.qr-card small,.nodes-toolbar,.channel-copy p,
.sub-card small,.node-type){
  color:#000!important;
  -webkit-text-fill-color:#000!important;
  text-shadow:
    0 0 1px rgba(255,255,255,1),
    0 0 3px rgba(255,255,255,.95),
    0 1px 0 rgba(255,255,255,.9),
    1px 2px 0 rgba(0,0,0,.55)!important;
}
/* Light theme: keep the requested black text and add a soft white halo/3D edge. */
html[data-theme="light"] body :where(.brand-subtitle,.hero p,.hero-badge small,.stat small,.quick-card small,
.section-title small,.sub-top small,.copy-row input,.node-copy input,.empty-state,
.footer-strip,.drawer-head small,.qr-card small,.nodes-toolbar,.channel-copy p,
.sub-card small,.node-type){
  color:#000!important;
  -webkit-text-fill-color:#000!important;
  text-shadow:
    0 0 1px rgba(255,255,255,1),
    0 0 3px rgba(255,255,255,1),
    0 0 6px rgba(255,255,255,.95),
    0 1px 0 rgba(255,255,255,.95),
    1px 2px 0 rgba(0,0,0,.35)!important;
}

/* NeoTenet dark-theme text override: white text with white shadow only. */
html[data-theme="dark"] body :where(h1,h2,h3,h4,h5,h6,p,span,small,strong,b,label,a,button,input,textarea,select,option,li,td,th,legend,summary){
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
  text-shadow:0 0 1px rgba(255,255,255,1),0 0 3px rgba(255,255,255,.95),0 0 6px rgba(255,255,255,.78)!important;
}
html[data-theme="dark"] body :where(input,textarea)::placeholder{
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
  text-shadow:0 0 1px rgba(255,255,255,1),0 0 3px rgba(255,255,255,.95),0 0 6px rgba(255,255,255,.78)!important;
}