/* Кошелёк: рога (донат) и клевер (за онлайн) */

.wIco{ width:1.15em; height:1.15em; flex:none; vertical-align:-.2em; }
.wIco.horn{ color:#E5A02D; }
.wIco.clover{ color:#C9D43A; }
[data-theme="light"] .wIco.horn{ color:#B9770E; }
[data-theme="light"] .wIco.clover{ color:#6B7F0F; }

/* баланс в шапке: заменяет строку «авторизован» */
html[data-authed="true"] #pstate{ display:none; }
.pwallet{
  display:none;
  align-items:center;
  gap:10px;
  font-size:12.5px;
  font-weight:800;
  line-height:1.2;
  font-variant-numeric:tabular-nums;
}
html[data-authed="true"] .pwallet{ display:flex; }
.pwallet span{ display:inline-flex; align-items:center; gap:4px; white-space:nowrap; }
.pwallet .wIco{ width:16px; height:16px; }

/* ник в шапке: у <button> по умолчанию чёрный текст, на тёмной кнопке он не читается */
.profileBtn{ color:var(--ink); }

/* профиль: панель кошелька */
.pfWallet .wbRow{
  display:grid;
  grid-template-columns:1fr 1fr auto;
  gap:12px;
  align-items:stretch;
  margin-top:8px;
}
@media (max-width:760px){ .pfWallet .wbRow{ grid-template-columns:1fr 1fr; } .pfWallet .wbOpen{ grid-column:1 / -1; } }
@media (max-width:460px){ .pfWallet .wbRow{ grid-template-columns:1fr; } }

.wbCur{
  display:flex; align-items:center; gap:12px;
  padding:12px 14px;
  border-radius:16px;
  border:1px solid var(--border);
  background:rgba(0,0,0,.14);
}
.wbCur .wIco{ width:34px; height:34px; }
.wbCur.horns{ border-color:rgba(229,160,45,.5); background:rgba(229,160,45,.07); }
.wbCur.clover{ border-color:rgba(201,212,58,.5); background:rgba(201,212,58,.06); }
.wbCur span{ display:block; font-size:11px; font-weight:800; letter-spacing:.07em; text-transform:uppercase; color:var(--muted2); }
.wbCur b{ display:block; font-size:24px; font-weight:900; line-height:1.1; font-variant-numeric:tabular-nums; }
.wbCur small{ display:block; font-size:12px; color:var(--muted); margin-top:2px; line-height:1.35; }
.wbOpen{ display:flex; align-items:center; }

.wBtn{
  padding:11px 18px;
  border-radius:14px;
  border:1px solid #E5A02D;
  background:linear-gradient(135deg,#F0B94A,#E5A02D 55%,#C6841A);
  color:#07100E;
  font:inherit; font-weight:900; font-size:14px;
  cursor:pointer;
  white-space:nowrap;
  transition:filter .15s, transform .15s;
}
.wBtn:hover{ filter:brightness(1.07); }
.wBtn:active{ transform:scale(.98); }
.wBtn:disabled{ opacity:.55; cursor:not-allowed; }
.wBtn.ghost{ background:transparent; color:var(--ink); border-color:var(--border); }
.wBtn.ghost:hover{ border-color:var(--accent); }
.wBtn.sm{ padding:7px 12px; font-size:13px; border-radius:11px; }

/* окно пополнения */
#walletModal .modal.walletBox{ width:min(940px,100%); max-height:min(92vh,900px); }
#walletModal [hidden]{ display:none !important; }
.wmGrid{ display:grid; grid-template-columns:minmax(0,1.1fr) minmax(0,1fr); gap:16px; align-items:start; }
@media (max-width:820px){ .wmGrid{ grid-template-columns:1fr; } }
.wmBalances{ display:grid; grid-template-columns:1fr 1fr; gap:12px; margin-bottom:14px; }
@media (max-width:520px){ .wmBalances{ grid-template-columns:1fr; } }

.wmCard{
  padding:14px 16px;
  border-radius:18px;
  border:1px solid var(--border);
  background:rgba(0,0,0,.14);
}
.wmCard h4{ margin:0 0 10px; font-size:12px; font-weight:900; letter-spacing:.08em; text-transform:uppercase; color:var(--muted2); }

.wmPacks{ display:grid; grid-template-columns:repeat(auto-fill, minmax(112px,1fr)); gap:8px; }
.wmPack{
  padding:10px 8px;
  border-radius:14px;
  border:1px solid var(--border);
  background:rgba(0,0,0,.14);
  color:var(--ink);
  font:inherit;
  cursor:pointer;
  text-align:center;
  transition:border-color .15s, transform .12s, background .15s;
}
.wmPack:hover{ transform:translateY(-1px); border-color:var(--accent); }
.wmPack.sel{ border-color:#E5A02D; background:rgba(229,160,45,.12); box-shadow:0 0 0 2px rgba(229,160,45,.28); }
.wmPack b{ display:block; font-size:16px; font-weight:900; }
.wmPack span{ display:flex; align-items:center; justify-content:center; gap:4px; font-size:12px; color:var(--muted); margin-top:2px; }

.wmField{ display:grid; gap:6px; margin-top:12px; }
.wmField label{ font-size:12px; font-weight:900; letter-spacing:.08em; text-transform:uppercase; color:var(--muted2); }
.wmInputRow{ display:flex; gap:8px; align-items:center; }
.wmInput{
  flex:1;
  min-width:0;
  padding:10px 12px;
  border-radius:12px;
  border:1px solid var(--border);
  background:rgba(0,0,0,.2);
  color:var(--ink);
  font:inherit; font-size:15px; font-weight:700;
  outline:none;
}
.wmInput:focus{ border-color:var(--accent); box-shadow:0 0 0 3px rgba(229,160,45,.18); }
[data-theme="light"] .wmInput{ background:rgba(255,255,255,.65); }
.wmSum{ font-size:15px; margin-top:12px; padding:10px 12px; border-radius:12px; background:rgba(229,160,45,.09); border:1px solid rgba(229,160,45,.35); }
.wmSum b{ font-weight:900; }

.wmProv{ display:grid; gap:8px; }
.wmProvRow{
  display:flex; gap:10px; align-items:center;
  padding:10px 12px;
  border-radius:12px;
  border:1px solid var(--border);
  cursor:pointer;
  font-size:14px;
}
.wmProvRow input{ accent-color:#E5A02D; }
.wmProvRow span{ text-transform:none; letter-spacing:0; font-size:14px; font-weight:700; color:var(--ink); }
.wmProvRow:has(input:checked){ border-color:#E5A02D; background:rgba(229,160,45,.08); }

.wmNote{ font-size:12.5px; line-height:1.5; color:var(--muted); margin-top:10px; }
.wmNote a{ color:var(--accent); }
.wmMsg{
  margin-top:10px;
  padding:10px 12px;
  border-radius:12px;
  font-size:13.5px; font-weight:600; line-height:1.45;
  border:1px solid var(--border);
}
.wmMsg.ok{ border-color:rgba(201,212,58,.55); color:#C9D43A; }
.wmMsg.err{ border-color:rgba(245,130,130,.6); color:#F58282; }
.wmMsg.info{ border-color:rgba(229,160,45,.5); }
[data-theme="light"] .wmMsg.ok{ color:#566a0a; }
[data-theme="light"] .wmMsg.err{ color:#b3261e; }

.wmTest{ margin-top:12px; padding:12px; border-radius:14px; border:1px dashed rgba(95,192,207,.7); background:rgba(95,192,207,.07); font-size:13.5px; }
.wmTest .wBtn{ margin-top:8px; }

/* история */
.wmHist{ display:grid; gap:6px; }
.wmItem{
  display:grid;
  grid-template-columns:auto minmax(0,1fr) auto;
  gap:10px;
  align-items:center;
  padding:8px 10px;
  border-radius:12px;
  border:1px solid var(--border);
  background:rgba(0,0,0,.1);
  font-size:13px;
}
.wmItem .wmWhat{ min-width:0; }
.wmItem .wmWhat b{ display:block; font-weight:700; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.wmItem .wmWhat small{ color:var(--muted2); font-size:11.5px; }
.wmItem .wmAmt{ font-weight:900; font-variant-numeric:tabular-nums; white-space:nowrap; }
.wmItem .wmAmt.plus{ color:#C9D43A; }
.wmItem .wmAmt.minus{ color:#F58282; }
.wmItem .wmAmt.pend{ color:var(--muted); font-weight:700; }
[data-theme="light"] .wmItem .wmAmt.plus{ color:#566a0a; }
.wmEmpty{ font-size:13px; color:var(--muted); padding:14px 4px; line-height:1.5; }

.wmAdmin{ margin-top:14px; }
.wmAdmin .wmInputRow{ flex-wrap:wrap; }
.wmAdmin select.wmInput{ flex:0 0 auto; min-width:120px; }

/* VIP-блок */
.wmVip{ margin:0 0 14px; padding:14px 16px; border:1px solid rgba(229,160,45,.35); border-radius:14px; background:rgba(229,160,45,.06); }
.wmVipHead{ margin-bottom:8px; }
.wmVipRow{ display:flex; justify-content:space-between; gap:10px; font-size:13px; color:var(--muted); margin-top:6px; }
.wmVipRow i{ font-style:normal; font-variant-numeric:tabular-nums; color:var(--ink); }
.wmBar{ height:6px; border-radius:6px; background:rgba(255,255,255,.1); overflow:hidden; margin-top:3px; }
.wmBar u{ display:block; height:100%; background:linear-gradient(90deg,#c6841a,#e5a02d); text-decoration:none; }
.wmVip small{ display:block; margin-top:8px; font-size:12px; color:var(--muted2); line-height:1.4; }
.wmPack b{ display:inline-flex; align-items:center; gap:4px; }
.wmVipWarn{ margin:6px 0 8px; padding:8px 10px; border-radius:10px; border:1px solid rgba(255,140,100,.5); background:rgba(255,120,80,.1); font-size:13px; }
