/* workspace.css — «Рабочий стол» (18.10.2026): свои окна на сетке gridstack */
.ws-content { max-width: none; padding-left: 16px; padding-right: 16px; }
.ws-hero { display: flex; justify-content: space-between; align-items: center; gap: 20px; text-align: left; margin-bottom: 14px; }
.ws-hero h1 { margin: 0; }
.ws-hcard { border: 1px solid var(--mx-gold-line); background: var(--mx-surface); border-radius: 14px; padding: 12px 18px; display: flex; gap: 22px; font-size: 14px; color: var(--text-secondary); }
.ws-hcard b { display: block; font-family: 'Unbounded', sans-serif; font-size: 20px; color: var(--text-color); }
.ws-bar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.ws-btn { display: inline-flex; gap: 8px; align-items: center; padding: 10px 15px; border-radius: 10px; font: 600 14px 'Onest', sans-serif; cursor: pointer;
  border: 1px solid var(--mx-gold-line); background: var(--mx-surface); color: var(--text-color); }
.ws-btn:hover { background: var(--mx-gold-wash); }
.ws-btn.main { background: linear-gradient(135deg, #f5d97a, #d4af37); color: #111; border: 0; }
.ws-btn.danger { border-color: rgba(239,68,68,.45); }
.ws-count { font-size: 14px; color: var(--text-secondary); margin-right: auto; }
.ws-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 70px 20px; color: var(--text-secondary); font-size: 15px; }
.ws-empty i { font-size: 40px; color: var(--gold, #d4af37); } .ws-empty b { font-size: 20px; color: var(--text-color); }

/* окно */
.grid-stack { min-height: 200px; }
.grid-stack-item-content.ws-w { --acc: #d4af37; --fs: 15px; display: flex; flex-direction: column; border-radius: 14px; overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--acc) 45%, transparent); background: rgba(14,14,18,var(--bga, .82)); font-size: var(--fs); }
body.light .grid-stack-item-content.ws-w { background: rgba(255,255,255,var(--bga, .9)); }
.ws-wh { display: flex; align-items: center; gap: 8px; padding: 8px 10px 8px 12px; border-bottom: 1px solid var(--mx-line); cursor: move; user-select: none; }
.ws-locked .ws-wh { cursor: default; }
.ws-wh i.ic { color: var(--acc); }
.ws-wh b { flex: 1; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ws-wh button { background: none; border: 0; color: var(--text-secondary); cursor: pointer; padding: 4px 6px; border-radius: 6px; font-size: 14px; }
.ws-wh button:hover { color: var(--text-color); background: var(--mx-surface-2); }
.ws-wb { flex: 1; min-height: 0; padding: 10px 12px; overflow: auto; position: relative; }
.ws-wb.flush { padding: 0; overflow: hidden; }
.ws-nodata { color: var(--text-secondary); font-size: 14px; padding: 8px 0; }
.ws-big { font-family: 'Unbounded', sans-serif; font-size: calc(var(--fs) * 2); font-weight: 700; line-height: 1.1; }
.ws-sub { color: var(--text-secondary); font-size: calc(var(--fs) * .85); }
.up { color: var(--up, #22c55e); } .dn { color: var(--dn, #ef4444); }
.ws-row { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--mx-line); }
.ws-row:last-child { border-bottom: 0; } .ws-row img { width: 18px; height: 18px; border-radius: 50%; vertical-align: -4px; margin-right: 6px; }
.ws-bar2 { height: 10px; border-radius: 6px; overflow: hidden; display: flex; margin: 8px 0; background: var(--mx-surface-2); }
.ws-bar2 i { display: block; height: 100%; }
.ws-news a { display: block; color: var(--text-color); text-decoration: none; padding: 7px 0; border-bottom: 1px solid var(--mx-line); line-height: 1.4; }
.ws-news a:hover { color: var(--acc); } .ws-news small { display: block; color: var(--text-secondary); font-size: 12px; }
.ws-note { width: 100%; height: 100%; resize: none; border: 0; outline: 0; background: transparent; color: var(--text-color); font: inherit; }
.ws-tick { display: flex; height: 100%; align-items: center; overflow: hidden; white-space: nowrap; }
.ws-tick-in { display: inline-flex; gap: 26px; animation: wsTick var(--dur, 60s) linear infinite; padding-left: 100%; }
.ws-tick-in span { display: inline-flex; gap: 6px; align-items: center; font-weight: 600; } .ws-tick-in img { width: 18px; height: 18px; border-radius: 50%; }
@keyframes wsTick { to { transform: translateX(-100%); } }
.ws-gauge { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; gap: 4px; }
.ws-gauge svg { width: min(100%, 260px); }
.ws-ind svg { width: 100%; height: 60px; display: block; margin-top: 8px; }

/* окна выбора и настроек */
.ws-modal { position: fixed; inset: 0; z-index: 9000; background: rgba(0,0,0,.6); display: flex; align-items: center; justify-content: center; padding: 16px; }
.ws-modal[hidden] { display: none; }
.ws-dlg { width: min(760px, 100%); max-height: 86vh; overflow: auto; background: #121216; border: 1px solid var(--mx-gold-line); border-radius: 16px; padding: 16px 18px; }
body.light .ws-dlg { background: #fff; }
.ws-dlg-h { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; font-size: 18px; }
.ws-dlg-h button { background: none; border: 0; color: var(--text-color); font-size: 20px; cursor: pointer; }
.ws-cat { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; }
.ws-cat button { text-align: left; display: flex; gap: 10px; align-items: flex-start; padding: 12px; border-radius: 12px; cursor: pointer;
  border: 1px solid var(--mx-line); background: var(--mx-surface); color: var(--text-color); font: 14px 'Onest', sans-serif; }
.ws-cat button:hover { border-color: var(--mx-gold-line); background: var(--mx-gold-wash); }
.ws-cat i { color: var(--gold, #d4af37); font-size: 18px; margin-top: 2px; } .ws-cat b { display: block; font-size: 15px; } .ws-cat small { color: var(--text-secondary); }
.ws-form { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 16px; }
.ws-form label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: var(--text-secondary); }
.ws-form input, .ws-form select { padding: 9px 10px; border-radius: 9px; border: 1px solid var(--mx-line-strong); background: var(--mx-surface); color: var(--text-color); font: 15px 'Onest', sans-serif; }
.ws-form input[type=color] { padding: 2px; height: 40px; }
.ws-form .full { grid-column: 1 / -1; }
.ws-form .ws-acts { grid-column: 1 / -1; display: flex; gap: 10px; justify-content: flex-end; }
@media (max-width: 760px) { .ws-hero { flex-direction: column; align-items: flex-start; } .ws-form { grid-template-columns: 1fr; } }
.ws-empty[hidden] { display: none; }
/* тонкие окна (бегущая строка): шапка прячется и всплывает при наведении поверх содержимого */
.ws-w.slim { position: relative; } .ws-w.slim .ws-wh { position: absolute; inset: 0 0 auto auto; z-index: 2; border: 0; border-radius: 0 0 0 10px; background: rgba(14,14,18,.92); opacity: 0; transition: opacity .15s; }
.ws-w.slim:hover .ws-wh { opacity: 1; } .ws-w.slim .ws-wh b { display: none; }
/* окно на весь экран (кнопка ⤢, выход — Esc) */
.grid-stack-item-content.ws-w.ws-full { position: fixed !important; inset: 12px !important; z-index: 100000; background: #0c0c10; box-shadow: 0 0 0 100vmax rgba(0,0,0,.6); }
body.light .grid-stack-item-content.ws-w.ws-full { background: #fff; }
/* монеты, по которым можно кликнуть — переключают связанные окна */
.ws-w [data-sym] { cursor: pointer; } .ws-w .ws-row[data-sym]:hover { background: var(--mx-gold-wash); }
.ws-has-full .top-bar, .ws-has-full .mrk-hello, .ws-has-full .mrk-btn, .ws-has-full .mrk-panel { display: none !important; }
.ws-wb.flush > .ws-nodata { padding: 12px; }
/* вкладки столов */
.ws-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.ws-tab { padding: 8px 14px; border-radius: 10px 10px 4px 4px; border: 1px solid var(--mx-line-strong); background: var(--mx-surface); color: var(--text-secondary); font: 600 14px 'Onest', sans-serif; cursor: pointer; }
.ws-tab small { opacity: .6; margin-left: 4px; } .ws-tab.on { color: var(--text-color); border-color: var(--mx-gold-line); background: var(--mx-gold-wash); }
.ws-tab.add, .ws-tab.del { padding: 8px 11px; } .ws-tab.del:hover { border-color: rgba(239,68,68,.5); color: #ef4444; }
.ws-count { margin-right: 6px; } .ws-sync { font-size: 13px; color: var(--text-secondary); margin-right: auto; }
.ws-cat button[hidden] { display: none; }
