@wsl233/dsh-gomoku 0.0.0-stage → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/ui/gomoku.css ADDED
@@ -0,0 +1,1549 @@
1
+ /* ==========================================================================
2
+ dsh-gomoku — white / orange UI
3
+ Scoped under .gk-app so it can live inside the DSH web shell safely.
4
+ ========================================================================== */
5
+
6
+ .gk-app,
7
+ .gk-app * {
8
+ box-sizing: border-box;
9
+ }
10
+
11
+ .gk-app {
12
+ --gk-orange: #f97316;
13
+ --gk-orange-strong: #ea580c;
14
+ --gk-orange-deep: #9a3412;
15
+ --gk-orange-soft: #fff3e6;
16
+ --gk-orange-line: #f6d7b8;
17
+ --gk-ink: #231f1a;
18
+ --gk-ink-soft: #5c554c;
19
+ --gk-muted: #948a7e;
20
+ --gk-line: #eee6dc;
21
+ --gk-paper: #ffffff;
22
+ --gk-board: #f6cf95;
23
+ --gk-board-line: #cd8640;
24
+ position: relative;
25
+ min-height: 100%;
26
+ width: 100%;
27
+ background:
28
+ radial-gradient(1100px 420px at 50% -160px, #fff7ee 0%, rgba(255, 247, 238, 0) 70%),
29
+ #ffffff;
30
+ color: var(--gk-ink);
31
+ font-family: "Segoe UI", "Microsoft YaHei", "PingFang SC", "Noto Sans SC", sans-serif;
32
+ padding: 24px 32px 30px;
33
+ -webkit-font-smoothing: antialiased;
34
+ text-rendering: optimizeLegibility;
35
+ }
36
+
37
+ .gk-app[hidden] {
38
+ display: none;
39
+ }
40
+
41
+ .gk-app [hidden] {
42
+ display: none !important;
43
+ }
44
+
45
+ .gk-shell {
46
+ width: 100%;
47
+ max-width: 1080px;
48
+ min-height: calc(100vh - 54px);
49
+ margin: 0 auto;
50
+ display: flex;
51
+ flex-direction: column;
52
+ gap: 16px;
53
+ container-type: inline-size;
54
+ }
55
+
56
+ /* ---------- header ---------- */
57
+
58
+ .gk-header {
59
+ display: flex;
60
+ align-items: center;
61
+ justify-content: space-between;
62
+ gap: 18px;
63
+ flex-wrap: wrap;
64
+ }
65
+
66
+ .gk-brand {
67
+ display: flex;
68
+ align-items: center;
69
+ gap: 11px;
70
+ min-width: 0;
71
+ }
72
+
73
+ .gk-brand-mark {
74
+ position: relative;
75
+ width: 36px;
76
+ height: 36px;
77
+ flex: 0 0 auto;
78
+ border-radius: 12px;
79
+ background: linear-gradient(145deg, #fb923c, #ea580c);
80
+ box-shadow: 0 8px 18px rgba(234, 88, 12, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.35);
81
+ display: grid;
82
+ place-items: center;
83
+ }
84
+
85
+ .gk-brand-mark::before {
86
+ content: "";
87
+ width: 15px;
88
+ height: 15px;
89
+ border-radius: 50%;
90
+ background: #fff;
91
+ box-shadow: 0 2px 0 rgba(154, 52, 18, 0.22);
92
+ }
93
+
94
+ .gk-brand-mark::after {
95
+ content: "";
96
+ position: absolute;
97
+ right: 7px;
98
+ bottom: 7px;
99
+ width: 7px;
100
+ height: 7px;
101
+ border-radius: 50%;
102
+ background: #fff7ed;
103
+ opacity: 0.72;
104
+ }
105
+
106
+ .gk-brand-copy {
107
+ display: flex;
108
+ align-items: baseline;
109
+ gap: 9px;
110
+ min-width: 0;
111
+ }
112
+
113
+ .gk-brand h1 {
114
+ margin: 0;
115
+ font-size: 21px;
116
+ line-height: 1.2;
117
+ letter-spacing: 0.08em;
118
+ font-weight: 750;
119
+ color: var(--gk-ink);
120
+ }
121
+
122
+ .gk-brand-sub {
123
+ font-size: 9.5px;
124
+ line-height: 1;
125
+ letter-spacing: 0.24em;
126
+ color: #b45309;
127
+ font-weight: 700;
128
+ white-space: nowrap;
129
+ }
130
+
131
+ .gk-preview-badge {
132
+ margin-left: 4px;
133
+ padding: 3px 8px;
134
+ border: 1px dashed #fdba74;
135
+ border-radius: 999px;
136
+ background: #fff7ed;
137
+ color: #b45309;
138
+ font-size: 10.5px;
139
+ line-height: 1.4;
140
+ white-space: nowrap;
141
+ }
142
+
143
+ .gk-toolbar {
144
+ display: flex;
145
+ align-items: center;
146
+ gap: 2px;
147
+ padding: 5px;
148
+ border: 1px solid var(--gk-line);
149
+ border-radius: 999px;
150
+ background: rgba(255, 255, 255, 0.96);
151
+ box-shadow: 0 10px 30px rgba(154, 84, 24, 0.08);
152
+ }
153
+
154
+ .gk-winrate {
155
+ display: inline-flex;
156
+ align-items: center;
157
+ gap: 6px;
158
+ height: 30px;
159
+ margin: 0 2px 0 4px;
160
+ padding: 0 10px;
161
+ border: 1px solid #f6c99e;
162
+ border-radius: 999px;
163
+ background: #ffffff;
164
+ color: var(--gk-orange-deep);
165
+ font-size: 11px;
166
+ font-weight: 650;
167
+ white-space: nowrap;
168
+ }
169
+
170
+ .gk-winrate-dot {
171
+ flex: 0 0 auto;
172
+ width: 8px;
173
+ height: 8px;
174
+ border-radius: 50%;
175
+ }
176
+
177
+ .gk-winrate-dot.is-black {
178
+ background: #24201c;
179
+ }
180
+
181
+ .gk-winrate-dot.is-white {
182
+ background: #ffffff;
183
+ border: 1px solid #b8a894;
184
+ }
185
+
186
+ .gk-winrate-sep {
187
+ margin: 0 1px;
188
+ color: #c9b8a5;
189
+ font-weight: 400;
190
+ }
191
+
192
+ .gk-winrate-text {
193
+ font-variant-numeric: tabular-nums;
194
+ }
195
+
196
+ .gk-tool {
197
+ position: relative;
198
+ width: 36px;
199
+ height: 36px;
200
+ padding: 0;
201
+ border: 0;
202
+ border-radius: 50%;
203
+ background: transparent;
204
+ color: #5f574e;
205
+ display: grid;
206
+ place-items: center;
207
+ cursor: pointer;
208
+ transition: background 140ms ease, color 140ms ease, transform 140ms ease;
209
+ }
210
+
211
+ .gk-tool svg {
212
+ width: 18px;
213
+ height: 18px;
214
+ display: block;
215
+ }
216
+
217
+ .gk-tool:hover {
218
+ background: var(--gk-orange-soft);
219
+ color: var(--gk-orange-strong);
220
+ }
221
+
222
+ .gk-tool:active {
223
+ transform: translateY(1px) scale(0.97);
224
+ }
225
+
226
+ .gk-tool:focus-visible,
227
+ .gk-player:focus-visible,
228
+ .gk-menu-row:focus-visible,
229
+ .gk-chip:focus-visible,
230
+ .gk-btn:focus-visible,
231
+ .gk-icon-btn:focus-visible {
232
+ outline: 2px solid #fb923c;
233
+ outline-offset: 2px;
234
+ }
235
+
236
+ .gk-tool[disabled] {
237
+ color: #c9c0b5;
238
+ cursor: not-allowed;
239
+ }
240
+
241
+ .gk-tool[disabled]:hover {
242
+ background: transparent;
243
+ color: #c9c0b5;
244
+ }
245
+
246
+ .gk-toolbar-divider {
247
+ width: 1px;
248
+ height: 18px;
249
+ margin: 0 3px;
250
+ background: var(--gk-line);
251
+ }
252
+
253
+ /* ---------- stage / board ---------- */
254
+
255
+ .gk-stage {
256
+ position: relative;
257
+ flex: 1;
258
+ display: grid;
259
+ grid-template-columns: 108px minmax(0, 1fr) 108px;
260
+ grid-template-areas:
261
+ "you board opponent"
262
+ ". status ."
263
+ ". hint .";
264
+ align-items: center;
265
+ justify-content: center;
266
+ column-gap: 14px;
267
+ row-gap: 13px;
268
+ padding: 10px 0 0;
269
+ }
270
+
271
+ .gk-board-wrap {
272
+ position: relative;
273
+ width: 100%;
274
+ max-width: 652px;
275
+ justify-self: center;
276
+ padding: 16px;
277
+ border-radius: 30px;
278
+ border: 1px solid #f2e2cf;
279
+ background: linear-gradient(155deg, #fffdf9 0%, #ffffff 55%, #fff8f0 100%);
280
+ box-shadow:
281
+ 0 28px 70px rgba(126, 66, 18, 0.12),
282
+ 0 8px 22px rgba(126, 66, 18, 0.06),
283
+ inset 0 1px 0 #ffffff;
284
+ }
285
+
286
+ .gk-board {
287
+ display: block;
288
+ width: 100%;
289
+ max-width: min(620px, 64vh);
290
+ aspect-ratio: 1 / 1;
291
+ border-radius: 17px;
292
+ background: var(--gk-board);
293
+ box-shadow:
294
+ inset 0 0 0 1px rgba(120, 66, 20, 0.16),
295
+ inset 0 10px 28px rgba(120, 66, 20, 0.06);
296
+ cursor: crosshair;
297
+ touch-action: manipulation;
298
+ }
299
+
300
+ .gk-board:focus-visible {
301
+ outline: 2px solid #fb923c;
302
+ outline-offset: 4px;
303
+ }
304
+
305
+ /* ---------- players ---------- */
306
+
307
+ .gk-board-wrap {
308
+ grid-area: board;
309
+ }
310
+
311
+ .gk-opponent-wrap {
312
+ grid-area: opponent;
313
+ position: relative;
314
+ align-self: start;
315
+ justify-self: center;
316
+ transform: translateX(-8px);
317
+ z-index: 30;
318
+ }
319
+
320
+ .gk-you-wrap {
321
+ grid-area: you;
322
+ position: static;
323
+ align-self: end;
324
+ justify-self: center;
325
+ padding-bottom: 4px;
326
+ transform: translateX(-8px);
327
+ z-index: 10;
328
+ }
329
+
330
+ .gk-statusbar {
331
+ grid-area: status;
332
+ justify-self: center;
333
+ }
334
+
335
+ .gk-hint-line {
336
+ grid-area: hint;
337
+ justify-self: center;
338
+ }
339
+
340
+ .gk-player {
341
+ display: flex;
342
+ flex-direction: column;
343
+ align-items: center;
344
+ gap: 5px;
345
+ padding: 0;
346
+ border: 0;
347
+ background: transparent;
348
+ color: var(--gk-ink);
349
+ cursor: pointer;
350
+ font: inherit;
351
+ }
352
+
353
+ .gk-you-wrap .gk-player {
354
+ cursor: pointer;
355
+ }
356
+
357
+ .gk-you-wrap .gk-player:hover .gk-player-label {
358
+ border-color: #f6c99e;
359
+ color: var(--gk-orange-deep);
360
+ }
361
+
362
+ .gk-avatar {
363
+ position: relative;
364
+ width: 58px;
365
+ height: 58px;
366
+ border: 0 !important;
367
+ background: transparent !important;
368
+ box-shadow: none;
369
+ display: grid;
370
+ place-items: center;
371
+ flex: 0 0 auto;
372
+ aspect-ratio: 1 / 1;
373
+ }
374
+
375
+ .gk-opponent-wrap .gk-avatar {
376
+ width: 88px;
377
+ height: 88px;
378
+ }
379
+
380
+ .gk-avatar-ring {
381
+ position: absolute;
382
+ inset: 0;
383
+ width: 100%;
384
+ height: 100%;
385
+ display: block;
386
+ pointer-events: none;
387
+ }
388
+
389
+ .gk-avatar img {
390
+ width: 100%;
391
+ height: 100%;
392
+ object-fit: cover;
393
+ border-radius: 50%;
394
+ clip-path: circle(50% at 50% 50%);
395
+ display: block;
396
+ }
397
+
398
+ .gk-avatar-glyph {
399
+ position: relative;
400
+ z-index: 1;
401
+ font-size: 26px;
402
+ font-weight: 800;
403
+ color: #b45309;
404
+ line-height: 1;
405
+ letter-spacing: -0.04em;
406
+ }
407
+
408
+ .gk-avatar-glyph.is-plus {
409
+ font-size: 42px;
410
+ font-weight: 300;
411
+ color: #c2410c;
412
+ transform: translateY(-2px);
413
+ }
414
+
415
+ .gk-avatar.is-fish,
416
+ .gk-avatar.is-generic,
417
+ .gk-avatar.is-local,
418
+ .gk-avatar.is-lan {
419
+ border-radius: 999px !important;
420
+ border-color: transparent !important;
421
+ background: transparent !important;
422
+ box-shadow: none;
423
+ }
424
+
425
+ .gk-avatar.is-you {
426
+ width: 72px;
427
+ height: 72px;
428
+ border-radius: 999px !important;
429
+ border-width: 2.5px;
430
+ background: transparent !important;
431
+ box-shadow: none;
432
+ }
433
+
434
+ .gk-avatar.is-you .gk-avatar-glyph {
435
+ color: #ea580c;
436
+ font-size: 25px;
437
+ font-weight: 700;
438
+ }
439
+
440
+ .gk-you-stone {
441
+ position: absolute;
442
+ right: 4px;
443
+ bottom: 4px;
444
+ width: 15px;
445
+ height: 15px;
446
+ border-radius: 50%;
447
+ border: 2px solid #ffffff;
448
+ background: #24201c;
449
+ box-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
450
+ }
451
+
452
+ .gk-you-stone[data-color="white"] {
453
+ background: #fffdf8;
454
+ }
455
+
456
+ .gk-plus {
457
+ position: absolute;
458
+ right: 4px;
459
+ bottom: 4px;
460
+ width: 24px;
461
+ height: 24px;
462
+ border-radius: 50%;
463
+ background: #f97316;
464
+ border: 2px solid #ffffff;
465
+ color: #ffffff;
466
+ display: grid;
467
+ place-items: center;
468
+ font-size: 17px;
469
+ font-weight: 700;
470
+ line-height: 1;
471
+ box-shadow: none;
472
+ }
473
+
474
+ .gk-player-label {
475
+ max-width: 108px;
476
+ padding: 3px 9px;
477
+ border: 1px solid var(--gk-line);
478
+ border-radius: 999px;
479
+ background: rgba(255, 255, 255, 0.96);
480
+ box-shadow: 0 3px 10px rgba(126, 66, 18, 0.06);
481
+ color: var(--gk-ink-soft);
482
+ font-size: 10.5px;
483
+ line-height: 1.45;
484
+ white-space: nowrap;
485
+ overflow: hidden;
486
+ text-overflow: ellipsis;
487
+ }
488
+
489
+ .gk-player-label strong {
490
+ color: var(--gk-orange-deep);
491
+ font-weight: 700;
492
+ }
493
+
494
+ .gk-player-label:focus-within {
495
+ max-width: 170px;
496
+ overflow: visible;
497
+ border-color: #fdba74;
498
+ }
499
+
500
+ .gk-you-name.is-editing {
501
+ display: inline-block;
502
+ min-width: 2.2em;
503
+ outline: none;
504
+ border-bottom: 1px dashed #fb923c;
505
+ white-space: nowrap;
506
+ }
507
+
508
+ /* ---------- mode menu ---------- */
509
+
510
+ .gk-menu {
511
+ position: absolute;
512
+ top: calc(100% + 9px);
513
+ right: 0;
514
+ width: 292px;
515
+ padding: 8px;
516
+ border: 1px solid var(--gk-line);
517
+ border-radius: 20px;
518
+ background: #ffffff;
519
+ box-shadow: 0 22px 58px rgba(84, 44, 10, 0.18), 0 3px 10px rgba(84, 44, 10, 0.06);
520
+ z-index: 40;
521
+ transform-origin: top right;
522
+ animation: gk-pop 150ms ease-out;
523
+ }
524
+
525
+ @keyframes gk-pop {
526
+ from {
527
+ opacity: 0;
528
+ transform: translateY(-4px) scale(0.98);
529
+ }
530
+ to {
531
+ opacity: 1;
532
+ transform: translateY(0) scale(1);
533
+ }
534
+ }
535
+
536
+ .gk-menu-title {
537
+ padding: 7px 10px 8px;
538
+ color: var(--gk-muted);
539
+ font-size: 10.5px;
540
+ letter-spacing: 0.12em;
541
+ font-weight: 650;
542
+ }
543
+
544
+ .gk-menu-row {
545
+ display: flex;
546
+ align-items: center;
547
+ gap: 10px;
548
+ width: 100%;
549
+ padding: 9px 10px;
550
+ border: 1px solid transparent;
551
+ border-radius: 13px;
552
+ background: transparent;
553
+ color: var(--gk-ink);
554
+ text-align: left;
555
+ font: inherit;
556
+ cursor: pointer;
557
+ transition: background 130ms ease, border-color 130ms ease;
558
+ }
559
+
560
+ .gk-menu-row:hover {
561
+ background: #fff8f1;
562
+ }
563
+
564
+ .gk-menu-row.is-active {
565
+ background: #fff7ed;
566
+ border-color: #fed7aa;
567
+ }
568
+
569
+ .gk-menu-thumb {
570
+ width: 38px;
571
+ height: 38px;
572
+ flex: 0 0 auto;
573
+ border-radius: 12px;
574
+ display: grid;
575
+ place-items: center;
576
+ background: #ffffff;
577
+ border: 1px solid #f6c99e;
578
+ color: #c2410c;
579
+ font-size: 15px;
580
+ font-weight: 750;
581
+ overflow: hidden;
582
+ }
583
+
584
+ .gk-menu-thumb img {
585
+ width: 100%;
586
+ height: 100%;
587
+ object-fit: cover;
588
+ display: block;
589
+ }
590
+
591
+ .gk-menu-thumb.is-fish {
592
+ border-color: #f6c99e;
593
+ background: #ffffff;
594
+ }
595
+
596
+ .gk-menu-copy {
597
+ min-width: 0;
598
+ flex: 1;
599
+ display: flex;
600
+ flex-direction: column;
601
+ gap: 2px;
602
+ }
603
+
604
+ .gk-menu-name {
605
+ font-size: 13px;
606
+ font-weight: 650;
607
+ line-height: 1.35;
608
+ }
609
+
610
+ .gk-menu-hint {
611
+ color: var(--gk-muted);
612
+ font-size: 10.5px;
613
+ line-height: 1.35;
614
+ }
615
+
616
+ .gk-menu-arrow {
617
+ width: 18px;
618
+ height: 18px;
619
+ flex: 0 0 auto;
620
+ color: #b9aa9a;
621
+ display: grid;
622
+ place-items: center;
623
+ }
624
+
625
+ .gk-menu-arrow svg {
626
+ width: 15px;
627
+ height: 15px;
628
+ }
629
+
630
+ .gk-menu-sep {
631
+ height: 1px;
632
+ margin: 6px 10px;
633
+ background: #f4ede4;
634
+ }
635
+
636
+ .gk-sub {
637
+ display: flex;
638
+ gap: 6px;
639
+ padding: 2px 10px 9px 58px;
640
+ flex-wrap: wrap;
641
+ }
642
+
643
+ .gk-levels {
644
+ display: flex;
645
+ align-items: center;
646
+ gap: 5px;
647
+ width: 100%;
648
+ margin-top: 2px;
649
+ padding-top: 7px;
650
+ border-top: 1px dashed #f2e4d4;
651
+ }
652
+
653
+ .gk-levels-label {
654
+ margin-right: 2px;
655
+ color: #9b8e80;
656
+ font-size: 10.5px;
657
+ white-space: nowrap;
658
+ }
659
+
660
+ .gk-chip.is-mini {
661
+ padding: 3px 8px;
662
+ font-size: 10.5px;
663
+ }
664
+
665
+ .gk-chip {
666
+ padding: 5px 10px;
667
+ border: 1px solid #f6c99e;
668
+ border-radius: 999px;
669
+ background: #ffffff;
670
+ color: var(--gk-orange-deep);
671
+ font: inherit;
672
+ font-size: 11.5px;
673
+ line-height: 1.4;
674
+ cursor: pointer;
675
+ transition: background 130ms ease, color 130ms ease, border-color 130ms ease;
676
+ }
677
+
678
+ .gk-chip:hover {
679
+ background: #fff3e6;
680
+ }
681
+
682
+ .gk-chip.is-active {
683
+ background: linear-gradient(145deg, #fb923c, #ea580c);
684
+ border-color: #ea580c;
685
+ color: #ffffff;
686
+ box-shadow: 0 4px 10px rgba(234, 88, 12, 0.18);
687
+ }
688
+
689
+ .gk-menu-note {
690
+ padding: 7px 10px 4px;
691
+ color: #a89c8e;
692
+ font-size: 10px;
693
+ line-height: 1.5;
694
+ }
695
+
696
+ /* ---------- thinking toast ---------- */
697
+
698
+ .gk-toast {
699
+ position: absolute;
700
+ top: 12px;
701
+ left: 50%;
702
+ z-index: 25;
703
+ display: flex;
704
+ align-items: center;
705
+ gap: 8px;
706
+ max-width: calc(100% - 26px);
707
+ padding: 7px 14px;
708
+ border: 1px solid #f3dfc9;
709
+ border-radius: 999px;
710
+ background: rgba(255, 252, 247, 0.94);
711
+ box-shadow: 0 9px 26px rgba(126, 66, 18, 0.12);
712
+ color: #94521d;
713
+ font-size: 12px;
714
+ line-height: 1.4;
715
+ white-space: nowrap;
716
+ overflow: hidden;
717
+ text-overflow: ellipsis;
718
+ opacity: 0;
719
+ transform: translate(-50%, -5px);
720
+ visibility: hidden;
721
+ pointer-events: none;
722
+ transition: opacity 160ms ease, transform 160ms ease, visibility 160ms ease;
723
+ }
724
+
725
+ .gk-toast.is-visible {
726
+ opacity: 1;
727
+ transform: translate(-50%, 0);
728
+ visibility: visible;
729
+ }
730
+
731
+ .gk-toast-text {
732
+ min-width: 0;
733
+ overflow: hidden;
734
+ text-overflow: ellipsis;
735
+ }
736
+
737
+ .gk-reviewbar {
738
+ position: absolute;
739
+ left: 50%;
740
+ bottom: 12px;
741
+ z-index: 26;
742
+ display: flex;
743
+ align-items: center;
744
+ gap: 6px;
745
+ padding: 6px;
746
+ border: 1px solid rgba(249, 115, 22, 0.22);
747
+ border-radius: 999px;
748
+ background: rgba(255, 255, 255, 0.94);
749
+ box-shadow: 0 6px 18px rgba(120, 72, 20, 0.16);
750
+ transform: translateX(-50%);
751
+ backdrop-filter: blur(8px);
752
+ }
753
+
754
+ .gk-reviewbar[hidden] {
755
+ display: none;
756
+ }
757
+
758
+ .gk-review-step,
759
+ .gk-review-close {
760
+ padding: 5px 10px;
761
+ border: 1px solid var(--gk-line);
762
+ border-radius: 999px;
763
+ background: #fff;
764
+ color: var(--gk-ink);
765
+ font: inherit;
766
+ font-size: 12px;
767
+ cursor: pointer;
768
+ }
769
+
770
+ .gk-review-step:hover,
771
+ .gk-review-close:hover {
772
+ border-color: rgba(249, 115, 22, 0.45);
773
+ color: var(--gk-orange-strong);
774
+ }
775
+
776
+ .gk-review-step:disabled {
777
+ color: #c9c0b5;
778
+ cursor: not-allowed;
779
+ }
780
+
781
+ .gk-review-pos {
782
+ padding: 0 4px;
783
+ color: var(--gk-muted);
784
+ font-size: 12px;
785
+ white-space: nowrap;
786
+ }
787
+
788
+ .gk-review-close {
789
+ border-color: rgba(249, 115, 22, 0.35);
790
+ color: var(--gk-orange-strong);
791
+ }
792
+
793
+ .gk-tool.is-active {
794
+ background: var(--gk-orange-soft);
795
+ color: var(--gk-orange-strong);
796
+ }
797
+
798
+ .gk-spinner {
799
+ width: 13px;
800
+ height: 13px;
801
+ flex: 0 0 auto;
802
+ border-radius: 50%;
803
+ border: 2px solid #f7d8b0;
804
+ border-top-color: var(--gk-orange);
805
+ animation: gk-spin 0.8s linear infinite;
806
+ }
807
+
808
+ @keyframes gk-spin {
809
+ to {
810
+ transform: rotate(360deg);
811
+ }
812
+ }
813
+
814
+ /* ---------- status ---------- */
815
+
816
+ .gk-statusbar {
817
+ display: flex;
818
+ align-items: center;
819
+ justify-content: center;
820
+ gap: 9px;
821
+ min-height: 24px;
822
+ color: var(--gk-muted);
823
+ font-size: 11.5px;
824
+ line-height: 1.5;
825
+ flex-wrap: wrap;
826
+ padding: 0 8px 2px;
827
+ }
828
+
829
+ .gk-status-dot {
830
+ width: 7px;
831
+ height: 7px;
832
+ border-radius: 50%;
833
+ background: #d7cabb;
834
+ flex: 0 0 auto;
835
+ }
836
+
837
+ .gk-status-dot.is-live {
838
+ background: var(--gk-orange);
839
+ box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.12);
840
+ }
841
+
842
+ .gk-status-sep {
843
+ width: 1px;
844
+ height: 11px;
845
+ background: #eee4d8;
846
+ }
847
+
848
+ .gk-mode-pill {
849
+ display: inline-flex;
850
+ align-items: center;
851
+ gap: 5px;
852
+ padding: 2px 8px;
853
+ border-radius: 999px;
854
+ background: #fff7ed;
855
+ color: #b45309;
856
+ font-size: 10.5px;
857
+ line-height: 1.5;
858
+ border: 1px solid #fde6cd;
859
+ }
860
+
861
+ /* ---------- LAN modal ---------- */
862
+
863
+ .gk-modal {
864
+ position: fixed;
865
+ inset: 0;
866
+ z-index: 200;
867
+ display: grid;
868
+ place-items: center;
869
+ padding: 22px;
870
+ background: rgba(37, 28, 18, 0.32);
871
+ backdrop-filter: blur(3px);
872
+ }
873
+
874
+ .gk-modal.is-hidden {
875
+ display: none;
876
+ }
877
+
878
+ .gk-dialog {
879
+ width: min(468px, 100%);
880
+ max-height: min(86vh, 720px);
881
+ overflow: auto;
882
+ padding: 24px;
883
+ border-radius: 26px;
884
+ background: #ffffff;
885
+ box-shadow: 0 34px 90px rgba(48, 27, 8, 0.3);
886
+ animation: gk-dialog 180ms ease-out;
887
+ }
888
+
889
+ @keyframes gk-dialog {
890
+ from {
891
+ opacity: 0;
892
+ transform: translateY(8px) scale(0.985);
893
+ }
894
+ to {
895
+ opacity: 1;
896
+ transform: translateY(0) scale(1);
897
+ }
898
+ }
899
+
900
+ .gk-dialog-head {
901
+ display: flex;
902
+ align-items: flex-start;
903
+ justify-content: space-between;
904
+ gap: 14px;
905
+ }
906
+
907
+ .gk-dialog h2 {
908
+ margin: 0;
909
+ font-size: 18px;
910
+ line-height: 1.35;
911
+ letter-spacing: 0.02em;
912
+ }
913
+
914
+ .gk-dialog p {
915
+ margin: 7px 0 0;
916
+ color: var(--gk-muted);
917
+ font-size: 11.5px;
918
+ line-height: 1.65;
919
+ }
920
+
921
+ .gk-dialog-close {
922
+ width: 30px;
923
+ height: 30px;
924
+ padding: 0;
925
+ border: 1px solid var(--gk-line);
926
+ border-radius: 50%;
927
+ background: #ffffff;
928
+ color: #7d7265;
929
+ cursor: pointer;
930
+ display: grid;
931
+ place-items: center;
932
+ }
933
+
934
+ .gk-dialog-close:hover {
935
+ background: #fff7ed;
936
+ color: var(--gk-orange-deep);
937
+ }
938
+
939
+ .gk-dialog-close svg {
940
+ width: 14px;
941
+ height: 14px;
942
+ }
943
+
944
+ .gk-link-box {
945
+ display: flex;
946
+ align-items: center;
947
+ gap: 8px;
948
+ margin-top: 16px;
949
+ padding: 10px 12px;
950
+ border: 1px dashed #f3b57a;
951
+ border-radius: 14px;
952
+ background: #fffaf3;
953
+ }
954
+
955
+ .gk-link-input {
956
+ flex: 1;
957
+ min-width: 0;
958
+ border: 0;
959
+ padding: 0;
960
+ background: transparent;
961
+ color: #7a4a1f;
962
+ font: 12px/1.5 "Cascadia Mono", "Consolas", monospace;
963
+ outline: none;
964
+ }
965
+
966
+ .gk-link-tools {
967
+ display: flex;
968
+ align-items: center;
969
+ gap: 5px;
970
+ flex: 0 0 auto;
971
+ }
972
+
973
+ .gk-icon-btn {
974
+ width: 30px;
975
+ height: 30px;
976
+ padding: 0;
977
+ border: 1px solid #f6d7b8;
978
+ border-radius: 9px;
979
+ background: #ffffff;
980
+ color: #b45309;
981
+ display: grid;
982
+ place-items: center;
983
+ cursor: pointer;
984
+ transition: background 130ms ease, border-color 130ms ease, color 130ms ease;
985
+ }
986
+
987
+ .gk-icon-btn svg {
988
+ width: 16px;
989
+ height: 16px;
990
+ display: block;
991
+ }
992
+
993
+ .gk-icon-btn:hover {
994
+ background: #fff7ed;
995
+ border-color: #fdba74;
996
+ color: #9a3412;
997
+ }
998
+
999
+ .gk-icon-btn.is-active {
1000
+ background: #ffedd5;
1001
+ border-color: #fb923c;
1002
+ color: #c2410c;
1003
+ box-shadow: inset 0 0 0 1px #fdba74;
1004
+ }
1005
+
1006
+ .gk-dialog-note {
1007
+ margin-top: 9px;
1008
+ color: #a3917f;
1009
+ font-size: 10.5px;
1010
+ line-height: 1.5;
1011
+ }
1012
+
1013
+ .gk-qr-slot {
1014
+ margin-top: 16px;
1015
+ padding: 16px;
1016
+ border: 1px solid var(--gk-line);
1017
+ border-radius: 18px;
1018
+ background: linear-gradient(160deg, #fffdf9, #fff8f0);
1019
+ display: flex;
1020
+ flex-direction: column;
1021
+ align-items: center;
1022
+ gap: 9px;
1023
+ }
1024
+
1025
+ .gk-qr-img {
1026
+ width: 168px;
1027
+ height: 168px;
1028
+ padding: 8px;
1029
+ border-radius: 14px;
1030
+ background: #ffffff;
1031
+ border: 1px solid #f0d7bf;
1032
+ display: block;
1033
+ }
1034
+
1035
+ .gk-qr-img[hidden] {
1036
+ display: none;
1037
+ }
1038
+
1039
+ .gk-qr-ph {
1040
+ width: 156px;
1041
+ height: 156px;
1042
+ border-radius: 14px;
1043
+ border: 1px dashed #e8c8a7;
1044
+ background:
1045
+ linear-gradient(90deg, rgba(249, 115, 22, 0.08) 1px, transparent 1px) 0 0 / 13px 13px,
1046
+ linear-gradient(rgba(249, 115, 22, 0.08) 1px, transparent 1px) 0 0 / 13px 13px,
1047
+ #ffffff;
1048
+ display: grid;
1049
+ place-items: center;
1050
+ color: #b45309;
1051
+ font-size: 10.5px;
1052
+ text-align: center;
1053
+ line-height: 1.6;
1054
+ }
1055
+
1056
+ .gk-qr-ph svg {
1057
+ width: 34px;
1058
+ height: 34px;
1059
+ margin-bottom: 6px;
1060
+ color: #f97316;
1061
+ }
1062
+
1063
+ .gk-dialog-actions {
1064
+ display: flex;
1065
+ gap: 8px;
1066
+ margin-top: 18px;
1067
+ justify-content: flex-end;
1068
+ }
1069
+
1070
+ .gk-btn {
1071
+ padding: 8px 14px;
1072
+ border: 1px solid var(--gk-line);
1073
+ border-radius: 10px;
1074
+ background: #ffffff;
1075
+ color: var(--gk-ink);
1076
+ font: inherit;
1077
+ font-size: 12px;
1078
+ cursor: pointer;
1079
+ }
1080
+
1081
+ .gk-btn:hover {
1082
+ background: #fff7ed;
1083
+ border-color: #f6c99e;
1084
+ color: var(--gk-orange-deep);
1085
+ }
1086
+
1087
+ .gk-btn.is-primary {
1088
+ border-color: #ea580c;
1089
+ background: linear-gradient(145deg, #fb923c, #ea580c);
1090
+ color: #ffffff !important;
1091
+ box-shadow: 0 7px 16px rgba(234, 88, 12, 0.22);
1092
+ }
1093
+
1094
+ .gk-btn.is-primary:hover {
1095
+ color: #ffffff;
1096
+ filter: brightness(1.03);
1097
+ }
1098
+
1099
+ .gk-code-input {
1100
+ width: 100%;
1101
+ min-height: 136px;
1102
+ margin-top: 14px;
1103
+ padding: 12px;
1104
+ border: 1px solid var(--gk-line);
1105
+ border-radius: 14px;
1106
+ background: #fffdf9;
1107
+ color: #6d4a2b;
1108
+ font: 11px/1.55 "Cascadia Mono", "Consolas", monospace;
1109
+ resize: vertical;
1110
+ outline: none;
1111
+ box-sizing: border-box;
1112
+ }
1113
+
1114
+ .gk-code-input:focus {
1115
+ border-color: #fdba74;
1116
+ box-shadow: 0 0 0 3px rgba(253, 186, 116, 0.22);
1117
+ }
1118
+
1119
+ .gk-code-input[readonly] {
1120
+ background: #fff8f0;
1121
+ }
1122
+
1123
+ /* ---------- DeepSeek log ---------- */
1124
+
1125
+ .gk-dslog {
1126
+ grid-column: 1 / -1;
1127
+ justify-self: center;
1128
+ width: min(100%, 680px);
1129
+ border: 1px solid #f6d7b8;
1130
+ border-radius: 12px;
1131
+ background: #fffdf9;
1132
+ padding: 8px 10px;
1133
+ font-size: 10.5px;
1134
+ color: #8a6a4d;
1135
+ }
1136
+
1137
+ .gk-dslog-toggle {
1138
+ border: 0;
1139
+ padding: 0;
1140
+ background: transparent;
1141
+ color: #b45309;
1142
+ font: inherit;
1143
+ font-weight: 650;
1144
+ cursor: pointer;
1145
+ }
1146
+
1147
+ .gk-dslog-toggle:hover {
1148
+ color: #9a3412;
1149
+ }
1150
+
1151
+ .gk-dslog-pre {
1152
+ max-height: 180px;
1153
+ overflow: auto;
1154
+ margin: 8px 0 0;
1155
+ padding: 8px;
1156
+ border-radius: 8px;
1157
+ background: #fff7ed;
1158
+ color: #6d4a2b;
1159
+ font: 10px/1.55 "Cascadia Mono", "Consolas", monospace;
1160
+ white-space: pre-wrap;
1161
+ word-break: break-word;
1162
+ }
1163
+
1164
+ .gk-dslog-pre[hidden] {
1165
+ display: none;
1166
+ }
1167
+
1168
+ /* ---------- fullscreen ---------- */
1169
+
1170
+ .gk-app.is-fullscreen {
1171
+ position: fixed;
1172
+ inset: 0;
1173
+ z-index: 9999;
1174
+ overflow: auto;
1175
+ padding: 24px 20px;
1176
+ background: #ffffff;
1177
+ display: flex;
1178
+ flex-direction: column;
1179
+ }
1180
+
1181
+ .gk-app.is-fullscreen .gk-shell {
1182
+ width: 100%;
1183
+ max-width: 1080px;
1184
+ margin: 0 auto;
1185
+ flex: 1;
1186
+ }
1187
+
1188
+ /* ---------- misc ---------- */
1189
+
1190
+ .gk-hint-line {
1191
+ color: #b3a698;
1192
+ font-size: 10.5px;
1193
+ line-height: 1.5;
1194
+ text-align: center;
1195
+ }
1196
+
1197
+ .gk-plugin-root {
1198
+ min-height: 100%;
1199
+ width: 100%;
1200
+ background: #ffffff;
1201
+ }
1202
+
1203
+ /* ---------- responsive ---------- */
1204
+
1205
+ @media (max-width: 920px) {
1206
+ .gk-app {
1207
+ padding: 20px 20px 26px;
1208
+ }
1209
+
1210
+ .gk-board {
1211
+ width: min(560px, 58vh, calc(100vw - 120px));
1212
+ }
1213
+
1214
+ .gk-shell {
1215
+ min-height: calc(100vh - 46px);
1216
+ }
1217
+ }
1218
+
1219
+ @media (max-width: 820px) {
1220
+ .gk-stage {
1221
+ display: flex;
1222
+ flex-direction: column;
1223
+ align-items: center;
1224
+ justify-content: flex-start;
1225
+ gap: 12px;
1226
+ padding-top: 12px;
1227
+ }
1228
+
1229
+ .gk-board-wrap {
1230
+ order: 1;
1231
+ }
1232
+
1233
+ .gk-board {
1234
+ width: min(560px, 56vh, calc(100vw - 56px));
1235
+ }
1236
+
1237
+ .gk-you-wrap {
1238
+ order: 2;
1239
+ align-self: flex-start;
1240
+ margin-left: 16px;
1241
+ padding-bottom: 0;
1242
+ transform: none;
1243
+ }
1244
+
1245
+ .gk-opponent-wrap {
1246
+ order: 3;
1247
+ align-self: flex-end;
1248
+ margin-right: 16px;
1249
+ transform: none;
1250
+ }
1251
+
1252
+ .gk-statusbar {
1253
+ order: 4;
1254
+ justify-content: center;
1255
+ }
1256
+
1257
+ .gk-hint-line {
1258
+ order: 5;
1259
+ }
1260
+
1261
+ .gk-menu {
1262
+ top: auto;
1263
+ bottom: calc(100% + 9px);
1264
+ }
1265
+ }
1266
+
1267
+ @media (max-width: 760px) {
1268
+ .gk-app {
1269
+ padding: 16px 12px 24px;
1270
+ }
1271
+
1272
+ .gk-shell {
1273
+ min-height: calc(100vh - 40px);
1274
+ gap: 12px;
1275
+ }
1276
+
1277
+ .gk-header {
1278
+ align-items: flex-start;
1279
+ flex-direction: column;
1280
+ gap: 10px;
1281
+ }
1282
+
1283
+ .gk-toolbar {
1284
+ width: 100%;
1285
+ justify-content: flex-start;
1286
+ overflow-x: auto;
1287
+ scrollbar-width: none;
1288
+ }
1289
+
1290
+ .gk-toolbar::-webkit-scrollbar {
1291
+ display: none;
1292
+ }
1293
+
1294
+ .gk-stage {
1295
+ justify-content: flex-start;
1296
+ padding-top: 20px;
1297
+ }
1298
+
1299
+ .gk-board-wrap {
1300
+ padding: 10px;
1301
+ border-radius: 24px;
1302
+ }
1303
+
1304
+ .gk-board {
1305
+ width: min(56vh, calc(100vw - 56px));
1306
+ border-radius: 13px;
1307
+ }
1308
+
1309
+ .gk-opponent-wrap .gk-avatar {
1310
+ width: 76px;
1311
+ height: 76px;
1312
+ }
1313
+
1314
+ .gk-avatar.is-you {
1315
+ width: 62px;
1316
+ height: 62px;
1317
+ }
1318
+
1319
+ .gk-avatar-glyph {
1320
+ font-size: 23px;
1321
+ }
1322
+
1323
+ .gk-avatar-glyph.is-plus {
1324
+ font-size: 36px;
1325
+ }
1326
+
1327
+ .gk-avatar.is-you .gk-avatar-glyph {
1328
+ font-size: 21px;
1329
+ }
1330
+
1331
+ .gk-plus {
1332
+ width: 23px;
1333
+ height: 23px;
1334
+ font-size: 15px;
1335
+ }
1336
+
1337
+ .gk-player-label {
1338
+ max-width: 100px;
1339
+ font-size: 10px;
1340
+ }
1341
+
1342
+ .gk-menu {
1343
+ right: 0;
1344
+ }
1345
+
1346
+ .gk-menu {
1347
+ width: min(286px, calc(100vw - 42px));
1348
+ right: -2px;
1349
+ }
1350
+
1351
+ .gk-sub {
1352
+ padding-left: 10px;
1353
+ }
1354
+
1355
+ .gk-toast {
1356
+ top: 8px;
1357
+ font-size: 11px;
1358
+ padding: 6px 11px;
1359
+ }
1360
+
1361
+ .gk-statusbar {
1362
+ justify-content: flex-start;
1363
+ padding: 0 4px;
1364
+ }
1365
+
1366
+ .gk-dialog {
1367
+ padding: 20px;
1368
+ border-radius: 22px;
1369
+ }
1370
+ }
1371
+
1372
+ @media (max-width: 420px) {
1373
+ .gk-tool {
1374
+ width: 34px;
1375
+ height: 34px;
1376
+ }
1377
+
1378
+ .gk-tool svg {
1379
+ width: 17px;
1380
+ height: 17px;
1381
+ }
1382
+
1383
+ .gk-brand h1 {
1384
+ font-size: 19px;
1385
+ }
1386
+
1387
+ .gk-brand-sub {
1388
+ display: none;
1389
+ }
1390
+
1391
+ .gk-preview-badge {
1392
+ font-size: 9.5px;
1393
+ padding: 2px 6px;
1394
+ }
1395
+
1396
+ .gk-board {
1397
+ width: calc(100vw - 46px);
1398
+ }
1399
+ }
1400
+
1401
+ /* ---------- container responsive (DSH 面板比视口窄) ---------- */
1402
+
1403
+ @container (max-width: 820px) {
1404
+ .gk-stage {
1405
+ display: flex;
1406
+ flex-direction: column;
1407
+ align-items: center;
1408
+ justify-content: flex-start;
1409
+ gap: 12px;
1410
+ padding-top: 12px;
1411
+ }
1412
+
1413
+ .gk-board-wrap {
1414
+ order: 1;
1415
+ width: 100%;
1416
+ max-width: 560px;
1417
+ }
1418
+
1419
+ .gk-board {
1420
+ width: 100%;
1421
+ max-width: min(560px, 56vh);
1422
+ }
1423
+
1424
+ .gk-you-wrap {
1425
+ order: 2;
1426
+ align-self: flex-start;
1427
+ margin-left: 16px;
1428
+ padding-bottom: 0;
1429
+ transform: none;
1430
+ }
1431
+
1432
+ .gk-opponent-wrap {
1433
+ order: 3;
1434
+ align-self: flex-end;
1435
+ margin-right: 16px;
1436
+ transform: none;
1437
+ }
1438
+
1439
+ .gk-statusbar {
1440
+ order: 4;
1441
+ justify-content: center;
1442
+ }
1443
+
1444
+ .gk-hint-line {
1445
+ order: 5;
1446
+ }
1447
+
1448
+ .gk-menu {
1449
+ top: auto;
1450
+ bottom: calc(100% + 9px);
1451
+ }
1452
+ }
1453
+
1454
+ @container (max-width: 620px) {
1455
+ .gk-header {
1456
+ align-items: flex-start;
1457
+ flex-direction: column;
1458
+ gap: 10px;
1459
+ }
1460
+
1461
+ .gk-toolbar {
1462
+ width: 100%;
1463
+ justify-content: flex-start;
1464
+ overflow-x: auto;
1465
+ scrollbar-width: none;
1466
+ }
1467
+
1468
+ .gk-toolbar::-webkit-scrollbar {
1469
+ display: none;
1470
+ }
1471
+ }
1472
+
1473
+ /* JS 兜底:不依赖容器查询支持,按面板实际宽度切布局。 */
1474
+
1475
+ .gk-app.is-panel-narrow .gk-stage {
1476
+ display: flex;
1477
+ flex-direction: column;
1478
+ align-items: center;
1479
+ justify-content: flex-start;
1480
+ gap: 12px;
1481
+ padding-top: 12px;
1482
+ }
1483
+
1484
+ .gk-app.is-panel-narrow .gk-board-wrap {
1485
+ order: 1;
1486
+ width: 100%;
1487
+ max-width: 560px;
1488
+ }
1489
+
1490
+ .gk-app.is-panel-narrow .gk-board {
1491
+ width: 100%;
1492
+ max-width: min(560px, 56vh);
1493
+ }
1494
+
1495
+ .gk-app.is-panel-narrow .gk-you-wrap {
1496
+ order: 2;
1497
+ align-self: flex-start;
1498
+ margin-left: 16px;
1499
+ padding-bottom: 0;
1500
+ transform: none;
1501
+ }
1502
+
1503
+ .gk-app.is-panel-narrow .gk-opponent-wrap {
1504
+ order: 3;
1505
+ align-self: flex-end;
1506
+ margin-right: 16px;
1507
+ transform: none;
1508
+ }
1509
+
1510
+ .gk-app.is-panel-narrow .gk-statusbar {
1511
+ order: 4;
1512
+ justify-content: center;
1513
+ }
1514
+
1515
+ .gk-app.is-panel-narrow .gk-hint-line {
1516
+ order: 5;
1517
+ }
1518
+
1519
+ .gk-app.is-panel-narrow .gk-menu {
1520
+ top: auto;
1521
+ bottom: calc(100% + 9px);
1522
+ }
1523
+
1524
+ .gk-app.is-panel-tiny .gk-header {
1525
+ align-items: flex-start;
1526
+ flex-direction: column;
1527
+ gap: 10px;
1528
+ }
1529
+
1530
+ .gk-app.is-panel-tiny .gk-toolbar {
1531
+ width: 100%;
1532
+ justify-content: flex-start;
1533
+ overflow-x: auto;
1534
+ scrollbar-width: none;
1535
+ }
1536
+
1537
+ .gk-app.is-panel-tiny .gk-toolbar::-webkit-scrollbar {
1538
+ display: none;
1539
+ }
1540
+
1541
+ @media (prefers-reduced-motion: reduce) {
1542
+ .gk-app *,
1543
+ .gk-app *::before,
1544
+ .gk-app *::after {
1545
+ animation-duration: 0.001ms !important;
1546
+ animation-iteration-count: 1 !important;
1547
+ transition-duration: 0.001ms !important;
1548
+ }
1549
+ }