/* Walt Wallet — dark theme. Scoped under html[data-theme="dark"]. */
:root[data-theme="dark"]{
  --w-bg:#0b1220;--w-surface:#121c2d;--w-surface-2:#0f1827;--w-ink:#e7eef8;--w-muted:#8ca0ba;
  --w-line:#26344a;--w-blue:#4d8dff;--w-blue-dark:#2f6bd8;--w-cyan:#4fd1e6;
  --w-green:#2fd39a;--w-red:#ff6b7d;--w-amber:#f0b34a;
  --ink:#e7eef8;--muted:#8ca0ba;--blue:#4d8dff;--blue2:#2f6bd8;--pale:#16233a;--line:#26344a;--white:#121c2d;
  --shadow:0 22px 60px rgba(0,0,0,.45);--w-shadow:0 16px 40px rgba(0,0,0,.38);--w-shadow-lg:0 30px 80px rgba(0,0,0,.6);
  color-scheme:dark;
}
[data-theme="dark"] body{
  background:radial-gradient(ellipse at 8% -5%,rgba(40,92,180,.22),transparent 40%),
             radial-gradient(ellipse at 92% 8%,rgba(30,150,180,.12),transparent 38%), var(--w-bg);
  color:var(--w-ink);
}
[data-theme="dark"] ::selection{background:#274c86;color:#fff}
[data-theme="dark"] a{color:var(--w-blue)}

/* header */
[data-theme="dark"] .topbar{border-bottom-color:#22304a;background:rgba(11,18,32,.86);backdrop-filter:blur(14px)}
[data-theme="dark"] .brand{color:var(--w-ink)}
[data-theme="dark"] .brand-light{color:#7f93ad}
[data-theme="dark"] .brand-mark{box-shadow:0 8px 18px rgba(77,141,255,.35)}
[data-theme="dark"] .icon-btn,[data-theme="dark"] .language-picker{background:#16233a;border-color:#2a3a54;color:var(--w-ink)}
[data-theme="dark"] .icon-btn:hover,[data-theme="dark"] .language-picker:hover{background:#1b2b45;border-color:#3a5578;box-shadow:0 4px 12px rgba(0,0,0,.3)}
[data-theme="dark"] .language-picker select{color:var(--w-ink)}
[data-theme="dark"] .network-dot{background:#2fd39a;box-shadow:0 0 0 4px rgba(47,211,154,.15)}

/* section tab bar */
[data-theme="dark"] .tab-bar{display:flex;gap:8px;padding:14px 0 4px;position:sticky;top:0;z-index:6;background:linear-gradient(180deg,var(--w-bg) 78%,transparent)}
[data-theme="dark"] .tab-btn{display:inline-flex;align-items:center;gap:8px;min-height:42px;padding:9px 16px;border:1px solid #2a3a54;border-radius:12px;background:#16233a;color:var(--w-muted);font:700 13px 'Onest',sans-serif;cursor:pointer;transition:all .18s ease}
[data-theme="dark"] .tab-btn span{font-size:16px;line-height:1}
[data-theme="dark"] .tab-btn:hover{border-color:#3a5578;color:var(--w-ink)}
[data-theme="dark"] .tab-btn.active{background:linear-gradient(135deg,#2f6bd8,#4d8dff);border-color:transparent;color:#fff;box-shadow:0 8px 20px rgba(77,141,255,.28)}
[data-theme="dark"] .tab-panel{padding-top:6px}
[data-theme="dark"] .tab-panel[hidden]{display:none}

/* hero */
[data-theme="dark"] .eyebrow{color:#6aa6ff}
[data-theme="dark"] .hero-copy h1,[data-theme="dark"] .section-head h1{color:#f2f6fc}
[data-theme="dark"] .hero-copy h1 span{background:linear-gradient(100deg,#5c9bff,#4fd1e6);-webkit-background-clip:text;background-clip:text;color:transparent}
[data-theme="dark"] .hero-copy p,[data-theme="dark"] .hint{color:#93a6bf}
[data-theme="dark"] .security-note{border-color:#2a3a54;background:rgba(22,35,58,.75);color:#a9bbd2}
[data-theme="dark"] .orb-a{background:radial-gradient(circle at 35% 35%,#4d8dff,#1d4f9e 70%);filter:blur(2px)}
[data-theme="dark"] .orb-b{background:radial-gradient(circle at 35% 35%,#4fd1e6,#1c6f86 70%);filter:blur(2px)}
[data-theme="dark"] .wallet-card{background:linear-gradient(135deg,#1d3a68,#122647);border-color:#2c4a78}
[data-theme="dark"] .float-pill{border-color:#2a3a54;background:rgba(18,28,45,.92);color:#b7c8dd}

/* wallet */
[data-theme="dark"] .section-head h1{font-size:35px}
[data-theme="dark"] .balance-card{background:linear-gradient(118deg,#123a72 0%,#1755a5 54%,#1c86c6 100%);border-color:rgba(255,255,255,.1);box-shadow:0 18px 40px rgba(0,0,0,.4)}
[data-theme="dark"] .balance-label{color:#dbe9ff}
[data-theme="dark"] .copy-btn{color:#e7f1ff;border-color:rgba(255,255,255,.28)}
[data-theme="dark"] .chain{border-color:#2a3a54;background:#16233a;color:#b9c9dd}
[data-theme="dark"] .chain:hover{border-color:#3a5578;background:#1b2b45}
[data-theme="dark"] .chain.active{border-color:#4d8dff;background:linear-gradient(180deg,#1c3358,#172945);color:#9cc4ff}
[data-theme="dark"] .panel{border-color:#26344a;background:#121c2d;box-shadow:var(--w-shadow)}
[data-theme="dark"] .panel-title{color:#e7eef8}
[data-theme="dark"] .panel label,[data-theme="dark"] .modal-card label{color:#9db0c8}
[data-theme="dark"] .panel input,[data-theme="dark"] .panel select,[data-theme="dark"] .panel textarea,
[data-theme="dark"] .modal-card input,[data-theme="dark"] .modal-card select,[data-theme="dark"] .modal-card textarea,
[data-theme="dark"] .p2p-filters select,[data-theme="dark"] .asset-toolbar input,[data-theme="dark"] .asset-toolbar select{
  border-color:#2c3c56;background:#0e1727;color:var(--w-ink)
}
[data-theme="dark"] .panel input:focus,[data-theme="dark"] .panel select:focus,[data-theme="dark"] .panel textarea:focus,
[data-theme="dark"] .modal-card input:focus,[data-theme="dark"] .modal-card select:focus,[data-theme="dark"] .modal-card textarea:focus{background:#101c30;border-color:#4d8dff;box-shadow:0 0 0 4px rgba(77,141,255,.14)}
[data-theme="dark"] .panel input::placeholder,[data-theme="dark"] .modal-card input::placeholder,[data-theme="dark"] .modal-card textarea::placeholder{color:#637893}
[data-theme="dark"] .btn.secondary{border-color:#2f405c;background:#18263c;color:#c6d6ea}
[data-theme="dark"] .btn.secondary:hover{border-color:#4d8dff;background:#1d2f4c}
[data-theme="dark"] .text-btn{color:#6aa6ff}
[data-theme="dark"] .empty-state{border-color:#2a3a54;background:#0f1827;color:#8ca0ba}
[data-theme="dark"] .security-row{border-color:#24334a}
[data-theme="dark"] .security-icon{background:#16233a;color:#8fc0ff}
[data-theme="dark"] .history-row{border-color:#24334a}
[data-theme="dark"] .history-row:hover{background:#16223a}
[data-theme="dark"] .asset-row.asset-card{border-color:#24334a}
[data-theme="dark"] .asset-icon{border-color:#2a3a54;background:linear-gradient(145deg,#1b3358,#162945);color:#8fc0ff}
[data-theme="dark"] .portfolio-strip{border-color:#2a3a54;background:linear-gradient(110deg,#142744,#12203a)}
[data-theme="dark"] .portfolio-strip strong{color:#dceaff}

/* modal & toast */
[data-theme="dark"] .modal{background:rgba(3,8,18,.72)}
[data-theme="dark"] .modal-card{border-color:#2a3a54;background:#121c2d;color:var(--w-ink);box-shadow:var(--w-shadow-lg)}
[data-theme="dark"] .modal-card h2{color:#f2f6fc}
[data-theme="dark"] .modal-card p{color:#9db0c8}
[data-theme="dark"] .modal-close{background:#1c2b44;color:#a9bbd2}
[data-theme="dark"] .modal-close:hover{background:#263b5c;color:#fff}
[data-theme="dark"] .toast{background:#16355e;border-color:#2a5a94;color:#eaf3ff}

/* footer */
[data-theme="dark"] footer{color:#6f829b}
[data-theme="dark"] .admin-link:hover{color:#6aa6ff}

/* login */
[data-theme="dark"] .login{border-color:#26344a!important;background:#121c2d!important;box-shadow:0 24px 70px rgba(0,0,0,.5)!important}
[data-theme="dark"] .login h1{color:#f2f6fc!important}
[data-theme="dark"] .login p,[data-theme="dark"] .login label{color:#9db0c8!important}
[data-theme="dark"] .login input{background:#0e1727!important;color:var(--w-ink)!important;border-color:#2c3c56!important}

/* drain guard */
[data-theme="dark"] .recipient-guard.danger{background:#3a1720;border-color:#6b2a38;color:#ff9bad}
[data-theme="dark"] .recipient-guard.ok{background:#12332a;border-color:#1f5c48;color:#6ee7b7}
[data-theme="dark"] .recipient-guard.neutral{background:#16233a;border-color:#2a3a54;color:#9db0c8}
[data-theme="dark"] .guard-banner.guard-block{background:#3a1720;border-color:#6b2a38;color:#ff9bad}
[data-theme="dark"] .guard-banner.guard-warn{background:#3a2c12;border-color:#6b5420;color:#f0c274}
[data-theme="dark"] .guard-banner.guard-ok{background:#12332a;border-color:#1f5c48;color:#6ee7b7}
[data-theme="dark"] .guard-feature .security-icon{background:#12332a;color:#6ee7b7}
[data-theme="dark"] .contact-row{border-color:#26344a;background:#0f1827}
[data-theme="dark"] .contact-main code{color:#9db0c8}
[data-theme="dark"] .login .message{color:#9db0c8}

/* ===== Intelligence ===== */
[data-theme="dark"] .intel-hero h1{color:#f2f6fc}
[data-theme="dark"] .intel-hero .hint{color:#93a6bf}
[data-theme="dark"] .ro-pill{border-color:#1f5c48;background:#12332a;color:#6ee7b7}
[data-theme="dark"] .field-hint{color:#9db0c8}
[data-theme="dark"] .chip{border-color:#2a3a54;background:#16233a;color:#b9c9dd}
[data-theme="dark"] .chip:hover{border-color:#4d8dff}
[data-theme="dark"] .chip.active{border-color:#4d8dff;background:linear-gradient(180deg,#1c3358,#172945);color:#9cc4ff}
[data-theme="dark"] .status{color:#8ca0ba}
[data-theme="dark"] .intel-nav a{border-color:#2a3a54;background:#16233a;color:#b9c9dd}
[data-theme="dark"] .intel-nav a:hover{border-color:#4d8dff;background:#1b2b45}
[data-theme="dark"] .mod{border-color:#26344a;background:#121c2d}
[data-theme="dark"] .mod-head{border-color:#24334a;background:linear-gradient(100deg,#16233a,#131f33)}
[data-theme="dark"] .mod-num{color:#6f829b}
[data-theme="dark"] .mod-head h2{color:#e7eef8}
[data-theme="dark"] .badge.IMPLEMENTED,[data-theme="dark"] .badge.CONFIRMED{background:#12332a;color:#6ee7b7;border-color:#1f5c48}
[data-theme="dark"] .badge.PARTIAL,[data-theme="dark"] .badge.ESTIMATED,[data-theme="dark"] .badge.PARTIAL_STATUS,[data-theme="dark"] .badge.ZERO_BALANCE,[data-theme="dark"] .badge.NOT_FOUND{background:#3a2c12;color:#f0c274;border-color:#6b5420}
[data-theme="dark"] .badge.MOCK{background:#261a44;color:#bfa6f5;border-color:#4a3678}
[data-theme="dark"] .badge.NOT_IMPLEMENTED,[data-theme="dark"] .badge.BLOCKED{background:#16233a;color:#8ca0ba;border-color:#2a3a54}
[data-theme="dark"] .badge.NOT_CHECKED,[data-theme="dark"] .badge.ERROR,[data-theme="dark"] .badge.UNKNOWN{background:#3a1720;color:#ff9bad;border-color:#6b2a38}
[data-theme="dark"] .state{border-color:#2a3a54;background:#0f1827;color:#8ca0ba}
[data-theme="dark"] .state.error{border-color:#6b2a38;background:#3a1720;color:#ff9bad}
[data-theme="dark"] .state.warn{border-color:#6b5420;background:#3a2c12;color:#f0c274}
[data-theme="dark"] .state.loading{border-color:#2a5a94;background:#122744;color:#8fc0ff}
[data-theme="dark"] .skeleton{background:linear-gradient(90deg,#18253a 25%,#243650 37%,#18253a 63%);background-size:400% 100%}
[data-theme="dark"] .note{color:#8ca0ba}
[data-theme="dark"] .kv{border-color:#24334a}
[data-theme="dark"] .kv .k{color:#8ca0ba}
[data-theme="dark"] .kv .v{color:#e7eef8}
[data-theme="dark"] .metric{border-color:#2a3a54;background:linear-gradient(110deg,#142744,#12203a)}
[data-theme="dark"] .metric .m-label{color:#8ca0ba}
[data-theme="dark"] .metric .m-value{color:#dceaff}
[data-theme="dark"] .metric.warn .m-value{color:#f0c274;background:#3a2c12}
[data-theme="dark"] .subhead{color:#9db0c8}
[data-theme="dark"] .row-item{border-color:#24334a;background:#0f1827}
[data-theme="dark"] .row-item .left b,[data-theme="dark"] .row-item .right{color:#e7eef8}
[data-theme="dark"] .row-item .left small{color:#8ca0ba}
[data-theme="dark"] .status-dot.mute{background:#54657e}
[data-theme="dark"] textarea.intel-input{border-color:#2c3c56;background:#0e1727;color:var(--w-ink)}
[data-theme="dark"] textarea.intel-input:focus{border-color:#4d8dff;background:#101c30}
[data-theme="dark"] .inline-form label{color:#9db0c8}
[data-theme="dark"] .inline-form input,[data-theme="dark"] .inline-form select{border-color:#2c3c56;background:#0e1727;color:var(--w-ink)}
[data-theme="dark"] .inline-form input:focus,[data-theme="dark"] .inline-form select:focus{background:#101c30}
[data-theme="dark"] .scenario-btn{border-color:#2a3a54;background:#16233a;color:#b9c9dd}
[data-theme="dark"] .scenario-btn:hover{border-color:#4d8dff;background:#1b2b45}
[data-theme="dark"] .example-q{background:#1c3358;color:#9cc4ff}
[data-theme="dark"] .example-q:hover{background:#254575}
[data-theme="dark"] .fact{border-color:#2f6bd8;background:#142744;color:#cfe0f6}
[data-theme="dark"] .fact .meta{color:#8ca0ba}
[data-theme="dark"] .assumption,[data-theme="dark"] .insufficient{color:#f0c274}
[data-theme="dark"] .limit-note{border-color:#26344a;background:#0f1827;color:#8ca0ba}

/* ===== P2P ===== */
[data-theme="dark"] .p2p-heading h1{color:#f2f6fc}
[data-theme="dark"] .p2p-live{border-color:#1f5c48;background:#12332a;color:#6ee7b7}
[data-theme="dark"] .p2p-warning{border-color:#6b5420;background:linear-gradient(110deg,#332812,#221c0e);color:#f0c274}
[data-theme="dark"] .p2p-filters{border-color:#26344a;background:#121c2d}
[data-theme="dark"] .p2p-filters select{background:#0e1727}
[data-theme="dark"] .p2p-actions{display:flex;flex-wrap:wrap;gap:8px;margin:4px 0 16px}
[data-theme="dark"] .offer-card{border-color:#26344a;background:#121c2d;box-shadow:0 8px 24px rgba(0,0,0,.3)}
[data-theme="dark"] .offer-card:hover{border-color:#3a5578;box-shadow:0 14px 30px rgba(0,0,0,.4)}
[data-theme="dark"] .offer-heading b{color:#e7eef8}
[data-theme="dark"] .offer-price{color:#9cc4ff}
[data-theme="dark"] .payment-tags span{border-color:#2a3a54;background:#16233a;color:#9db0c8}
[data-theme="dark"] .offer-reputation{color:#8ca0ba}
[data-theme="dark"] .merchant-badge{border-color:#1f5c48;background:#12332a;color:#6ee7b7}
[data-theme="dark"] .trade-card{border-color:#24334a}
[data-theme="dark"] .trade-status{border-color:#2a5a94;background:#122744;color:#9cc4ff}
[data-theme="dark"] .chat-log{border-color:#2a3a54;background:#0e1727}
[data-theme="dark"] .chat-log p{border-color:#26344a;background:#16233a;color:#cfe0f6}
[data-theme="dark"] .chat-log .chat-mine{background:#1c3358;border-color:#2f6bd8}
[data-theme="dark"] .payment-details,[data-theme="dark"] .evidence-list{border-color:#26344a;background:#0e1727;color:#b9c9dd}
[data-theme="dark"] .evidence-list a{color:#6aa6ff}
[data-theme="dark"] .p2p-trades label{color:#9db0c8}
[data-theme="dark"] .p2p-trades input,[data-theme="dark"] .p2p-trades textarea{border-color:#2c3c56;background:#0e1727;color:var(--w-ink)}

/* mobile bottom nav */
[data-theme="dark"] .mobile-bottom-nav{background:rgba(15,24,39,.94)!important;border-top-color:#26344a;box-shadow:0 -8px 24px rgba(0,0,0,.35)}
[data-theme="dark"] .mobile-bottom-nav button{color:#8ca0ba}
[data-theme="dark"] .mobile-bottom-nav button.active{color:#6aa6ff}
[data-theme="dark"] .mobile-quick-actions .quick-receive{background:#16233a;color:#9cc4ff;border-color:#2a3a54}
[data-theme="dark"] body.telegram-miniapp{background:var(--tg-theme-bg-color,var(--w-bg));color:var(--tg-theme-text-color,var(--w-ink))}

@media(prefers-reduced-motion:reduce){[data-theme="dark"] *,[data-theme="dark"] *::before,[data-theme="dark"] *::after{animation-duration:.01ms!important;transition-duration:.01ms!important}}

/* ===== POLISH PASS · dark counterparts ===== */
[data-theme="dark"] .panel{box-shadow:0 1px 0 rgba(255,255,255,.035) inset,0 18px 44px rgba(0,0,0,.30)}
[data-theme="dark"] .action-grid .panel:hover{border-color:#3a5578;box-shadow:0 22px 50px rgba(0,0,0,.45)}
[data-theme="dark"] .balance-card:before{background:radial-gradient(420px 220px at 12% -10%,rgba(255,255,255,.16),transparent 70%)}
[data-theme="dark"] .hero-art:before{background-image:radial-gradient(circle,rgba(93,157,255,.22) 1px,transparent 1.5px)}
[data-theme="dark"] .eyebrow::before{opacity:.7}
[data-theme="dark"] .language-picker{background:#16233a;border-color:#2a3a54}
[data-theme="dark"] .language-picker>span{color:#6aa6ff}
[data-theme="dark"] .language-picker:focus-within{border-color:#4d8dff;box-shadow:0 0 0 4px rgba(77,141,255,.16)}
[data-theme="dark"] .tab-btn{transition:transform .18s var(--w-ease),box-shadow .18s var(--w-ease),border-color .18s var(--w-ease),color .18s var(--w-ease),background .18s var(--w-ease)}
[data-theme="dark"] .toast{border-left-color:#4d8dff}
[data-theme="dark"] .text-btn:hover{color:#8fc0ff}
[data-theme="dark"] .loading-placeholder:before,[data-theme="dark"] .loading-placeholder:after{background:linear-gradient(90deg,#1b2b45 25%,#273b5a 37%,#1b2b45 63%);background-size:400% 100%}
[data-theme="dark"] .portfolio-strip:after{border-color:rgba(120,180,255,.14);box-shadow:0 0 0 22px rgba(120,180,255,.04),0 0 0 46px rgba(120,180,255,.025)}
[data-theme="dark"] .asset-row.asset-card:hover{background:#16223a}
[data-theme="dark"] .offer-card:before{background:linear-gradient(90deg,transparent,#4d8dff,transparent)}
[data-theme="dark"] .merchant-badge{box-shadow:inset 0 0 0 1px rgba(255,255,255,.06)}
[data-theme="dark"] .mod:hover{box-shadow:0 18px 44px rgba(0,0,0,.42)}
[data-theme="dark"] .badge{box-shadow:inset 0 0 0 1px rgba(255,255,255,.06)}
[data-theme="dark"] .metric:hover{box-shadow:0 14px 30px rgba(0,0,0,.38)}
[data-theme="dark"] .row-item:hover{background:#16233a;border-color:#2a3a54}