/* Виджет игрового сервера и страница привязки. Цвета берутся из темы форума. */
.gs { margin: 0 0 18px; padding: 18px 20px; display: grid; gap: 16px; }
.gs-head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.gs-ic { width: 44px; height: 44px; flex: none; border-radius: 12px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); }
.gs-ic svg { width: 22px; height: 22px; }
.gs-ic.ok { background: var(--ok-soft); color: var(--ok); }
.gs-title { flex: 1 1 200px; min-width: 0; }
.gs-title h2 { margin: 0; font-size: 1.1rem; line-height: 1.25; overflow-wrap: anywhere; }
.gs-state { margin: 2px 0 0; display: flex; align-items: center; gap: 7px; font-size: .86rem; color: var(--ink-2); }
.gs-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--bad); flex: none; }
[data-gs][data-on="1"] .gs-dot, .gs-dot.on { background: var(--ok); box-shadow: 0 0 0 0 color-mix(in srgb, var(--ok) 55%, transparent); animation: gs-pulse 2.2s infinite; }
@keyframes gs-pulse { 70% { box-shadow: 0 0 0 7px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
.gs-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.gs-body { display: grid; gap: 16px; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); align-items: start; }
.gs-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.gs-stat { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r); padding: 11px 13px; min-width: 0; }
.gs-stat b { display: block; font-size: 1.15rem; line-height: 1.2; overflow-wrap: anywhere; }
.gs-stat small { color: var(--ink-3); }
.gs-online { grid-column: 1 / -1; }
.gs-online b { font-size: 1.7rem; }
.gs-online b i { font-style: normal; color: var(--ink-3); margin: 0 3px; }
.gs-bar { height: 7px; border-radius: 99px; background: var(--line); margin-top: 8px; overflow: hidden; }
.gs-bar span { display: block; height: 100%; background: var(--accent); border-radius: inherit; transition: width .6s ease; }
[data-gs][data-on="0"] .gs-stats { opacity: .6; }
.gs-players h3 { margin: 0 0 8px; font-size: .95rem; }
.gs-players ul { list-style: none; margin: 0; padding: 0; max-height: 240px; overflow: auto; border: 1px solid var(--line); border-radius: var(--r); }
.gs-players li { display: flex; align-items: baseline; gap: 8px; padding: 7px 12px; border-bottom: 1px solid var(--line); font-size: .9rem; }
.gs-players li:last-child { border-bottom: 0; }
.gs-pname { font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gs-forum { font-size: .8rem; color: var(--accent); text-decoration: none; white-space: nowrap; }
.gs-forum:hover { text-decoration: underline; }
.gs-job { margin-left: auto; color: var(--ink-3); font-size: .82rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 40%; }
.gs-time { color: var(--ink-3); font-size: .8rem; min-width: 48px; text-align: right; white-space: nowrap; }
.gs-empty { margin: 8px 0 0; }
@media (max-width: 760px) { .gs-body { grid-template-columns: 1fr; } .gs { padding: 15px; } }

/* Привязка аккаунта */
.gs-linked { display: flex; gap: 14px; align-items: center; margin: 6px 0 12px; }
.gs-linked p { margin: 2px 0 0; }
.gs-steps { list-style: none; counter-reset: gs; margin: 12px 0 16px; padding: 0; display: grid; gap: 9px; }
.gs-steps li { counter-increment: gs; display: grid; grid-template-columns: 28px 1fr; gap: 2px 10px; align-items: start; }
.gs-steps li::before { content: counter(gs); grid-row: span 2; width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font-weight: 700; font-size: .85rem; }
.gs-steps span { color: var(--ink-3); font-size: .88rem; }
.gs-code { background: var(--surface-2); border: 1px dashed var(--line-2); border-radius: var(--r); padding: 16px; margin: 0 0 14px; text-align: center; display: grid; gap: 6px; justify-items: center; }
.gs-code small { color: var(--ink-3); text-transform: uppercase; letter-spacing: .08em; }
.gs-code-num { font-family: var(--f-mono); font-size: 2.4rem; letter-spacing: .18em; line-height: 1.1; }
.gs-code code { background: var(--accent-soft); color: var(--accent); padding: 4px 10px; border-radius: 8px; font-size: 1rem; }
.gs-code.expired { opacity: .5; }
.gs-code p { margin: 0; }

/* Админка */
.gs-admin-state { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.gs-cfg { background: var(--pre-bg); color: var(--pre-ink); padding: 12px 14px; border-radius: var(--r); overflow: auto; user-select: all; font-family: var(--f-mono); font-size: .86rem; }
