/* ── Board / card lobby KZ (V8 · KM · JILI) ── */
.board-lobby-kz {
    --board-accent: #1e88e5;
    --board-accent-soft: #e8f2fe;
    --board-bg: #eaf2fc;
    --board-surface: #ffffff;
    --board-text: #1e293b;
    --board-muted: #94a3b8;
    background: var(--board-bg);
    min-height: calc(100vh - 112px);
}

.board-lobby-kz .lobby-top-cats {
    background: var(--board-surface);
}

.board-lobby-kz__body {
    display: flex;
    align-items: stretch;
    min-height: calc(100vh - 180px);
}

/* Sidebar */
.board-sidebar {
    flex: 0 0 92px;
    width: 92px;
    background: var(--board-surface);
    border-right: 1px solid #eef2f7;
    display: flex;
    flex-direction: column;
}

.board-sidebar__search {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 48px;
    border-bottom: 1px solid #eef2f7;
    color: var(--board-accent);
    cursor: pointer;
}

.board-sidebar__search i {
    font-size: 18px;
}

.board-sidebar__search-input {
    display: none;
    padding: 6px 8px;
    border-bottom: 1px solid #eef2f7;
}

.board-sidebar__search-input.open {
    display: block;
}

.board-sidebar__search-input input {
    width: 100%;
    padding: 6px 8px;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    font-size: 11px;
    outline: none;
}

.board-sidebar__list {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 6px 0 14px;
    list-style: none;
    margin: 0;
}

.board-sidebar__list::-webkit-scrollbar {
    width: 0;
}

.board-provider {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 90px;
    padding: 10px 4px 8px;
    margin: 5px 0 5px 5px;
    border-radius: 0 12px 12px 0;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    -webkit-tap-highlight-color: transparent;
    box-sizing: border-box;
    color: var(--board-accent);
}

.board-provider__logo {
    width: 54px;
    height: 54px;
    min-width: 54px;
    min-height: 54px;
    object-fit: contain;
    object-position: center center;
    border-radius: 10px;
    background: #fff;
    padding: 4px;
    display: block;
    border: 1px solid #bfdbfe00;
    box-shadow: none;
    image-rendering: -webkit-optimize-contrast;
}

.board-provider__logo--fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 800;
    color: var(--board-accent);
    background: #e8f2fe;
}

.board-provider__name {
    margin-top: 6px;
    width: 100%;
    min-height: 26px;
    font-size: 15px;
    font-weight: 600;
    text-align: center;
    line-height: 1.2;
    color: var(--board-accent);
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    word-break: break-word;
    padding: 0 2px;
    letter-spacing: 0.2px;
}

.board-provider.active {
    background: var(--board-accent);
    color: #fff;
}

.board-provider.active::after {
    content: "";
    position: absolute;
    top: calc(50% - 8px);
    right: -8px;
    width: 0;
    height: 0;
    border-width: 8px 0 8px 9px;
    border-style: solid;
    border-color: transparent;
    border-left-color: var(--board-accent);
    z-index: 2;
}

.board-provider.active .board-provider__name {
    color: #fff;
    font-weight: 800;
}

.board-provider.active .board-provider__logo {
    border-color: rgba(255, 255, 255, 0.45);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    background: #fff;
}

.board-provider--disabled {
    opacity: 0.78;
}

.board-provider--disabled .board-provider__name {
    color: #5a9e8c;
}

/* Main */
.board-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    background: var(--board-surface);
}

.board-main__toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px 10px;
    border-bottom: 1px solid #eef2f7;
    background: var(--board-surface);
}

.board-tabs {
    display: flex;
    gap: 20px;
    align-items: center;
}

.board-tab {
    position: relative;
    padding: 0;
    border: none;
    background: none;
    font-size: 14px;
    font-weight: 700;
    color: var(--board-muted);
    cursor: pointer;
    letter-spacing: 0.2px;
}

.board-tab.active {
    color: var(--board-accent);
}

.board-tab.active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -10px;
    height: 2px;
    background: var(--board-accent);
    border-radius: 2px;
}

.board-tools {
    display: flex;
    gap: 14px;
    align-items: center;
    color: var(--board-muted);
}

.board-tools__btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    padding: 0;
    border: none;
    background: none;
    cursor: pointer;
}

.board-tools__btn img {
    width: 18px;
    height: 18px;
    object-fit: contain;
}

.board-tools__btn i {
    font-size: 16px;
}

/* Grid */
.board-grid-wrap {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 10px 8px 88px;
    box-sizing: border-box;
}

.board-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px 8px;
    width: 100%;
    box-sizing: border-box;
}

.board-game {
    display: flex;
    flex-direction: column;
    min-width: 0;
    width: 100%;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.board-game__thumb {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 100%;
    border-radius: 12px;
    overflow: hidden;
    background: #f1f5f9;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
    flex-shrink: 0;
}

.board-game__thumb img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    object-fit: cover;
    object-position: center center;
    display: block;
}

.board-game__name {
    flex: 1;
    min-height: 30px;
    margin-top: 6px;
    font-size: 11px;
    font-weight: 500;
    color: var(--board-text);
    text-align: center;
    line-height: 1.3;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    word-break: break-word;
    padding: 0 2px;
}

.board-grid-loading,
.board-grid-empty,
.board-grid-maintenance {
    grid-column: 1 / -1;
    text-align: center;
    padding: 48px 16px;
    color: var(--board-muted);
    font-size: 13px;
    line-height: 1.5;
}

.board-grid-loading i {
    display: block;
    font-size: 24px;
    margin-bottom: 8px;
    color: var(--board-accent);
}

.board-grid-maintenance {
    color: #64748b;
}
