:root { --bg:#14231d; --panel:#1b3027; --panel2:#172b24; --line:#536044; --text:#f5efdb; --muted:#bfccb8; --gold:#e7c878; --ink:#17241d; --danger:#ffb4a4; --ok:#9fd8a8; }
@media (prefers-color-scheme: light) { :root { --bg:#f3f1e8; --panel:#fff; --panel2:#faf8f0; --line:#d6d1bd; --text:#232a22; --muted:#667061; --gold:#8a6511; --ink:#fff; --danger:#b3382b; --ok:#2c7a3e; } }
* { box-sizing: border-box; }
body { margin:0; background:var(--bg); color:var(--text); font:16px/1.5 Inter,"Segoe UI",system-ui,sans-serif; }
h1,h2,h3 { font-family:Georgia,Cambria,serif; font-weight:500; margin:0 0 12px; }
h1 { font-size:28px; } h2 { font-size:22px; } h3 { font-size:16px; font-family:inherit; font-weight:600; color:var(--muted); }
button, input, textarea, select { font:inherit; color:inherit; }
input, textarea { width:100%; padding:11px 12px; background:var(--panel2); border:1px solid var(--line); border-radius:8px; margin-top:6px; }
textarea { min-height:110px; resize:vertical; }
label { display:block; margin:0 0 14px; font-size:14px; color:var(--muted); }
button { cursor:pointer; min-height:44px; padding:10px 18px; border-radius:8px; border:1px solid var(--line); background:transparent; font-weight:600; }
button.primary { background:var(--gold); border-color:var(--gold); color:var(--ink); }
button.danger { border-color:var(--danger); color:var(--danger); }
button:disabled { opacity:.5; cursor:default; }
a { color:var(--gold); }
.wrap { max-width:960px; margin:0 auto; padding:24px 16px 60px; }
.auth { max-width:420px; margin:9vh auto; }
.card { background:var(--panel); border:1px solid var(--line); border-radius:14px; padding:22px; margin-bottom:16px; }
.top { display:flex; align-items:center; gap:12px; justify-content:space-between; flex-wrap:wrap; margin-bottom:16px; }
.brand { font:700 22px Georgia,serif; color:var(--gold); }
.tabs { display:flex; gap:6px; flex-wrap:wrap; margin-bottom:16px; }
.tabs button { border-radius:20px; min-height:38px; padding:6px 16px; }
.tabs button[aria-pressed=true] { background:var(--gold); border-color:var(--gold); color:var(--ink); }
.row { display:flex; gap:10px; flex-wrap:wrap; align-items:center; }
.row > * { flex:0 0 auto; }
.grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(270px,1fr)); gap:14px; }
.hero { background:var(--panel2); border:1px solid var(--line); border-radius:12px; padding:16px; }
.hero h2 { margin-bottom:6px; }
dl { display:grid; grid-template-columns:auto 1fr; gap:4px 12px; margin:10px 0 0; font-size:14px; }
dt { color:var(--muted); } dd { margin:0; text-align:right; }
.tag { display:inline-block; padding:1px 9px; border-radius:10px; border:1px solid var(--line); font-size:12px; }
.tag.good { color:var(--ok); border-color:var(--ok); } .tag.bad { color:var(--danger); border-color:var(--danger); }
.muted { color:var(--muted); font-size:14px; } .err { color:var(--danger); min-height:20px; margin:6px 0; } .ok { color:var(--ok); }
.code { font:700 28px ui-monospace,Consolas,monospace; letter-spacing:.25em; padding:12px 16px; background:var(--panel2); border:1px dashed var(--gold); border-radius:10px; display:inline-block; margin:8px 0; user-select:all; }
.scroll { overflow-x:auto; }
table { width:100%; border-collapse:collapse; font-size:14px; } th, td { text-align:left; padding:8px 10px; border-bottom:1px solid var(--line); } th { color:var(--muted); font-weight:500; }
.msg { padding:10px 12px; border:1px solid var(--line); border-radius:10px; margin-bottom:8px; white-space:pre-wrap; background:var(--panel2); }
.msg.admin { border-color:var(--gold); }
tr.click { cursor:pointer; } tr.click:hover { background:var(--panel2); }
.copied { color: var(--good, #7fe08a); font-weight: 700; min-height: 1.2em; margin: 6px 0; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
a.btn { display: inline-block; padding: 10px 16px; border-radius: 10px; border: 1px solid var(--gold); color: inherit; text-decoration: none; }

/* Магазин (владелец 2026-10-27: оплата через сайт). */
select { width:100%; padding:11px 12px; background:var(--panel2); border:1px solid var(--line); border-radius:8px; margin-top:6px; }
.shop-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(200px,1fr)); gap:12px; }
.product { display:flex; flex-direction:column; align-items:center; gap:6px; text-align:center; background:var(--panel2); border:1px solid var(--line); border-radius:12px; padding:14px; }
.product img { width:100%; max-width:220px; aspect-ratio:3/2; object-fit:contain; }
.product img.gem { width:64px; height:64px; aspect-ratio:auto; }
.product h3 { margin:0; color:var(--text); font:600 17px Georgia,serif; }
.product .gems { color:var(--ok); font-weight:700; }
.product > button:last-child { margin-top:auto; width:100%; }
button.link { min-height:32px; padding:4px 8px; border:0; color:var(--gold); text-decoration:underline; font-weight:500; }
.items { list-style:none; margin:0; padding:0; width:100%; font-size:13px; text-align:left; }
.items li { display:flex; justify-content:space-between; gap:8px; padding:3px 0; border-bottom:1px solid var(--line); }
.pay-note { font-weight:600; }
