BlueGit

timfa filemanager

Files

filemanager / public / style.css

style.css

style.css 25.7 KiB Download Raw
1/* =========================================================
2 RESET & CUSTOM PROPERTIES
3 ========================================================= */
4*,
5*::before,
6*::after {
7 box-sizing: border-box;
8 margin: 0;
9 padding: 0;
10}
11
12:root {
13 --bg: #0f1117;
14 --surface: #1a1d27;
15 --surface2: #21242f;
16 --border: #2e3247;
17 --accent: #5b7fff;
18 --accent-hover: #7b9fff;
19 --text: #e8eaf0;
20 --text-muted: #7880a0;
21 --danger: #e05c6e;
22 --success: #3fcf8e;
23 --radius: 10px;
24 --topbar-h: 56px;
25 --sidebar-w: 300px;
26 --transition: 0.18s ease;
27}
28
29html,
30body {
31 height: 100%;
32 font-family: system-ui, -apple-system, sans-serif;
33}
34
35body {
36 background: var(--bg);
37 color: var(--text);
38 overflow: hidden;
39}
40
41.hidden {
42 display: none !important;
43}
44
45.muted {
46 color: var(--text-muted);
47}
48
49.error {
50 color: var(--danger);
51 font-size: 0.85rem;
52 margin-top: 0.3rem;
53}
54
55/* =========================================================
56 AUTH OVERLAY
57 ========================================================= */
58.overlay {
59 position: fixed;
60 inset: 0;
61 background: var(--bg);
62 display: flex;
63 align-items: center;
64 justify-content: center;
65 z-index: 100;
66}
67
68.auth-card {
69 background: var(--surface);
70 border: 1px solid var(--border);
71 border-radius: var(--radius);
72 padding: 2.5rem 2rem;
73 width: min(420px, 92vw);
74}
75
76.auth-card h1 {
77 font-size: 1.6rem;
78 margin-bottom: 0.5rem;
79}
80
81.auth-subtitle {
82 font-size: 0.88rem;
83 color: var(--text-muted);
84 margin-bottom: 1.2rem;
85}
86
87#auth-form label {
88 display: flex;
89 flex-direction: column;
90 gap: 0.3rem;
91 font-size: 0.85rem;
92 color: var(--text-muted);
93 margin-bottom: 1rem;
94}
95
96#auth-form input {
97 background: var(--bg);
98 border: 1px solid var(--border);
99 border-radius: 6px;
100 padding: 0.55rem 0.75rem;
101 color: var(--text);
102 font-size: 1rem;
103 outline: none;
104 transition: border-color var(--transition);
105}
106
107#auth-form input:focus {
108 border-color: var(--accent);
109}
110
111/* =========================================================
112 BUTTONS
113 ========================================================= */
114button {
115 cursor: pointer;
116 border: none;
117 border-radius: 6px;
118 font-size: 0.9rem;
119 transition: background var(--transition), color var(--transition);
120}
121
122.icon-btn {
123 display: flex;
124 align-items: center;
125 gap: 0.4rem;
126 background: transparent;
127 color: var(--text-muted);
128 padding: 0.4rem 0.7rem;
129 border-radius: 6px;
130 position: relative;
131}
132
133.icon-btn:hover {
134 background: var(--surface2);
135 color: var(--text);
136}
137
138.icon-btn svg {
139 width: 18px;
140 height: 18px;
141}
142
143.topbar-badge {
144 position: absolute;
145 top: -0.25rem;
146 right: -0.3rem;
147 min-width: 1.1rem;
148 height: 1.1rem;
149 padding: 0 0.28rem;
150 border-radius: 999px;
151 background: #d33131;
152 color: #fff;
153 font-size: 0.68rem;
154 font-weight: 700;
155 line-height: 1.1rem;
156 text-align: center;
157 border: 1px solid var(--surface);
158}
159
160button[type="submit"],
161.primary {
162 background: var(--accent);
163 color: #fff;
164 padding: 0.55rem 1.2rem;
165 font-weight: 600;
166 width: 100%;
167 margin-top: 0.5rem;
168}
169
170button[type="submit"]:hover,
171.primary:hover {
172 background: var(--accent-hover);
173}
174
175button.danger {
176 background: var(--surface2);
177 color: var(--danger);
178 padding: 0.55rem 1.2rem;
179 width: 100%;
180 margin-top: 0.5rem;
181}
182
183button.danger:hover {
184 background: var(--border);
185}
186
187button.danger.admin-update-highlight {
188 animation: admin-update-pulse 0.9s ease-in-out 2;
189}
190
191@keyframes admin-update-pulse {
192 0% {
193 box-shadow: 0 0 0 0 rgba(211, 49, 49, 0.55);
194 transform: scale(1);
195 }
196
197 50% {
198 box-shadow: 0 0 0 10px rgba(211, 49, 49, 0);
199 transform: scale(1.02);
200 }
201
202 100% {
203 box-shadow: 0 0 0 0 rgba(211, 49, 49, 0);
204 transform: scale(1);
205 }
206}
207
208/* =========================================================
209 TOP BAR
210 ========================================================= */
211#app {
212 display: flex;
213 flex-direction: column;
214 height: 100vh;
215}
216
217#topbar {
218 height: var(--topbar-h);
219 background: var(--surface);
220 border-bottom: 1px solid var(--border);
221 display: flex;
222 align-items: center;
223 padding: 0 1rem;
224 gap: 0.5rem;
225 flex-shrink: 0;
226}
227
228#topbar > #btn-refresh {
229 flex: 0 0 auto;
230}
231
232#breadcrumb-wrap {
233 flex: 1;
234 min-width: 0;
235}
236
237#breadcrumb {
238 display: flex;
239 align-items: center;
240 flex-wrap: wrap;
241 gap: 0.1rem;
242 font-size: 0.9rem;
243 white-space: nowrap;
244 overflow: hidden;
245}
246
247#breadcrumb .crumb {
248 color: var(--text-muted);
249 background: none;
250 padding: 0.2rem 0.35rem;
251 border-radius: 4px;
252 text-decoration: none;
253 cursor: pointer;
254}
255
256#breadcrumb .crumb:hover {
257 color: var(--text);
258 background: var(--surface2);
259}
260
261#breadcrumb .crumb.active {
262 color: var(--text);
263 cursor: default;
264}
265
266#breadcrumb .sep {
267 color: var(--border);
268 user-select: none;
269}
270
271#topbar-actions {
272 display: flex;
273 align-items: center;
274 gap: 0.25rem;
275 flex-shrink: 0;
276 position: relative;
277}
278
279.topbar-dropdown {
280 position: relative;
281}
282
283.topbar-dropdown-menu {
284 position: absolute;
285 top: calc(100% + 0.4rem);
286 left: 0;
287 min-width: 180px;
288 background: var(--surface);
289 border: 1px solid var(--border);
290 border-radius: var(--radius);
291 box-shadow: 0 12px 22px rgba(0, 0, 0, 0.28);
292 padding: 0.35rem;
293 z-index: 140;
294 display: none;
295}
296
297.topbar-dropdown-menu--right {
298 left: auto;
299 right: 0;
300}
301
302.topbar-dropdown.open .topbar-dropdown-menu {
303 display: flex;
304 flex-direction: column;
305 gap: 0.2rem;
306}
307
308.topbar-menu-item {
309 display: flex;
310 align-items: center;
311 gap: 0.48rem;
312 width: 100%;
313 background: transparent;
314 color: var(--text-muted);
315 border-radius: 6px;
316 padding: 0.45rem 0.55rem;
317 text-align: left;
318}
319
320.topbar-menu-item svg {
321 width: 16px;
322 height: 16px;
323 flex: 0 0 auto;
324}
325
326.topbar-menu-item:hover {
327 background: var(--surface2);
328 color: var(--text);
329}
330
331.top-search {
332 display: flex;
333 align-items: center;
334 gap: 0.35rem;
335 margin-right: 0.2rem;
336}
337
338.top-search input {
339 width: min(34vw, 300px);
340 min-width: 150px;
341 background: var(--bg);
342 border: 1px solid var(--border);
343 border-radius: 6px;
344 color: var(--text);
345 font-size: 0.88rem;
346 padding: 0.42rem 0.6rem;
347 outline: none;
348}
349
350.top-search input:focus {
351 border-color: var(--accent);
352}
353
354#btn-search {
355 padding: 0.36rem 0.62rem;
356}
357
358.global-favicon-preview {
359 width: 18px;
360 height: 18px;
361 display: inline-flex;
362 align-items: center;
363 justify-content: center;
364 border-radius: 4px;
365 overflow: hidden;
366 color: #fff;
367}
368
369.global-favicon-preview svg,
370.global-favicon-preview img {
371 width: 100%;
372 height: 100%;
373 display: block;
374 object-fit: cover;
375}
376
377.icon-btn.icon-only {
378 width: 2rem;
379 height: 2rem;
380 padding: 0;
381 justify-content: center;
382}
383
384/* =========================================================
385 MAIN + SIDEBAR LAYOUT
386 ========================================================= */
387#main-content {
388 flex: 1;
389 overflow-y: auto;
390 padding: 1.25rem;
391 position: relative;
392}
393
394#folder-stats {
395 margin-bottom: 0.8rem;
396 font-size: 0.85rem;
397}
398
399/* Drop overlay */
400#drop-overlay {
401 position: absolute;
402 inset: 0;
403 background: rgba(91, 127, 255, 0.12);
404 border: 3px dashed var(--accent);
405 border-radius: var(--radius);
406 display: flex;
407 align-items: center;
408 justify-content: center;
409 z-index: 10;
410 font-size: 1.4rem;
411 color: var(--accent);
412 pointer-events: none;
413}
414
415/* When sidebar is open, shrink main content */
416#app.sidebar-open #main-content {
417 margin-right: var(--sidebar-w);
418}
419
420/* =========================================================
421 FILE GRID
422 ========================================================= */
423#file-grid {
424 display: grid;
425 grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
426 gap: 0.75rem;
427}
428
429.file-item {
430 display: flex;
431 flex-direction: column;
432 align-items: center;
433 padding: 0.9rem 0.5rem 0.7rem;
434 border-radius: var(--radius);
435 border: 1px solid transparent;
436 cursor: pointer;
437 user-select: none;
438 transition: background var(--transition), border-color var(--transition);
439 text-align: center;
440 gap: 0.4rem;
441 position: relative;
442 touch-action: manipulation;
443}
444
445.file-item:hover {
446 background: var(--surface);
447 border-color: var(--border);
448}
449
450.file-item.file-item--preview-placeholder {
451 visibility: hidden;
452 pointer-events: none;
453}
454
455.file-item.selected {
456 background: var(--surface2);
457 border-color: var(--accent);
458}
459
460.file-item .icon {
461 width: 52px;
462 height: 52px;
463 display: flex;
464 align-items: center;
465 justify-content: center;
466 position: relative;
467}
468
469.file-item .icon.thumb-pending::after {
470 content: '';
471 position: absolute;
472 width: 14px;
473 height: 14px;
474 left: 50%;
475 top: 50%;
476 border: 2px solid rgba(232, 234, 240, 0.35);
477 border-top-color: var(--accent);
478 border-radius: 50%;
479 animation: icon-thumb-spin 0.75s linear infinite;
480 background: rgba(15, 17, 23, 0.85);
481}
482
483@keyframes icon-thumb-spin {
484 from {
485 transform: translate(-50%, -50%) rotate(0deg);
486 }
487
488 to {
489 transform: translate(-50%, -50%) rotate(360deg);
490 }
491}
492
493.file-item .icon svg {
494 width: 100%;
495 height: 100%;
496}
497
498.file-item .icon .watched-overlay {
499 position: absolute;
500 left: 50%;
501 top: 50%;
502 width: 28px;
503 height: 28px;
504 transform: translate(-50%, -50%);
505 display: flex;
506 align-items: center;
507 justify-content: center;
508 pointer-events: none;
509 border-radius: 50%;
510 background: rgba(15, 17, 23, 0.45);
511}
512
513.file-item .icon .watched-overlay--partway {
514 width: 16.8px;
515 height: 16.8px;
516}
517
518.file-item .icon .watched-overlay--partway path {
519 fill: #8f98a5;
520}
521
522.file-item .icon .watched-overlay-svg {
523 width: 100%;
524 height: 100%;
525}
526
527.file-item .name {
528 font-size: 0.8rem;
529 word-break: break-all;
530 max-width: 100%;
531 line-height: 1.3;
532 color: var(--text);
533}
534
535/* =========================================================
536 SIDEBAR
537 ========================================================= */
538#sidebar {
539 position: fixed;
540 top: var(--topbar-h);
541 right: 0;
542 bottom: 0;
543 width: var(--sidebar-w);
544 background: var(--surface);
545 border-left: 1px solid var(--border);
546 padding: 1.25rem;
547 overflow-y: auto;
548 z-index: 20;
549 display: flex;
550 flex-direction: column;
551 gap: 0.75rem;
552}
553
554#sidebar-close {
555 display: none;
556 align-items: center;
557 justify-content: center;
558 width: 1.7rem;
559 height: 1.7rem;
560 border: 1px solid transparent;
561 border-radius: 999px;
562 background: transparent;
563 color: var(--text-muted);
564 font-size: 1rem;
565 line-height: 1;
566}
567
568#sidebar-close:hover {
569 background: var(--surface2);
570 color: var(--text);
571}
572
573#sidebar-icon {
574 display: flex;
575 justify-content: center;
576}
577
578#sidebar-icon svg {
579 width: 64px;
580 height: 64px;
581}
582
583#sidebar-name {
584 font-size: 1rem;
585 word-break: break-all;
586 text-align: center;
587}
588
589#sidebar-meta {
590 display: grid;
591 grid-template-columns: auto 1fr;
592 gap: 0.3rem 0.75rem;
593}
594
595#sidebar-meta dt {
596 color: var(--text-muted);
597 font-size: 0.8rem;
598 font-weight: 600;
599}
600
601#sidebar-meta dd {
602 font-size: 0.8rem;
603 word-break: break-all;
604}
605
606#sidebar-meta .root-access-list {
607 margin: 0;
608 padding-left: 1rem;
609}
610
611#sidebar-meta .root-access-list li {
612 margin: 0.12rem 0;
613}
614
615#sidebar-actions {
616 display: flex;
617 flex-direction: column;
618 gap: 0.5rem;
619 margin-top: 0.5rem;
620}
621
622#sidebar-actions button {
623 background: var(--surface2);
624 color: var(--text);
625 padding: 0.5rem 0.8rem;
626 text-align: left;
627}
628
629#sidebar-actions button:hover {
630 background: var(--border);
631}
632
633#sidebar-actions button.danger {
634 color: var(--danger);
635}
636
637/* ─── Duplicates panel ─────────────────────────────────── */
638#sidebar-duplicates {
639 margin-top: 1rem;
640 border-top: 1px solid var(--border);
641 padding-top: 0.75rem;
642}
643
644.sidebar-duplicates-heading {
645 font-size: 0.75rem;
646 font-weight: 600;
647 text-transform: uppercase;
648 letter-spacing: 0.05em;
649 color: var(--text-muted, #888);
650 margin: 0 0 0.4rem;
651}
652
653.sidebar-duplicates-list {
654 list-style: none;
655 margin: 0;
656 padding: 0;
657 display: flex;
658 flex-direction: column;
659 gap: 0.25rem;
660}
661
662.sidebar-duplicate-entry {
663 display: block;
664 width: 100%;
665 background: var(--surface2);
666 color: var(--text);
667 padding: 0.35rem 0.6rem;
668 text-align: left;
669 font-size: 0.8rem;
670 white-space: nowrap;
671 overflow: hidden;
672 text-overflow: ellipsis;
673 border-radius: var(--radius);
674 cursor: pointer;
675}
676
677.sidebar-duplicate-entry:hover {
678 background: var(--border);
679}
680
681.admin-size-feedback {
682 font-size: 0.82rem;
683 margin: 0.25rem 0 0.5rem;
684 padding: 0.25rem 0.5rem;
685 border-radius: var(--radius);
686}
687
688.admin-size-feedback.ok {
689 color: var(--accent);
690}
691
692.admin-size-feedback.err {
693 color: #e55;
694}
695
696/* =========================================================
697 MODALS
698 ========================================================= */
699.modal-overlay {
700 position: fixed;
701 inset: 0;
702 background: rgba(0, 0, 0, 0.65);
703 display: flex;
704 align-items: center;
705 justify-content: center;
706 z-index: 11000;
707}
708
709#file-conflict-modal,
710#overwrite-modal {
711 z-index: 11150;
712}
713
714.modal {
715 background: var(--surface);
716 border: 1px solid var(--border);
717 border-radius: var(--radius);
718 padding: 2rem;
719 width: min(560px, 94vw);
720 max-height: 90vh;
721 overflow-y: auto;
722 position: relative;
723}
724
725.modal.small {
726 width: min(340px, 94vw);
727}
728
729.modal h2 {
730 font-size: 1.3rem;
731 margin-bottom: 1.25rem;
732}
733
734.modal h3 {
735 font-size: 1rem;
736 color: var(--text-muted);
737 margin: 1rem 0 0.5rem;
738}
739
740.modal-close {
741 position: absolute;
742 top: 0.75rem;
743 right: 0.75rem;
744 background: none;
745 color: var(--text-muted);
746 font-size: 1.1rem;
747 padding: 0.25rem 0.5rem;
748}
749
750.modal-close:hover {
751 color: var(--text);
752}
753
754/* =========================================================
755 FOLDER ICON PICKER
756 ========================================================= */
757.folder-icon-modal {
758 width: min(680px, 94vw);
759 max-height: 90vh;
760 display: flex;
761 flex-direction: column;
762 gap: 0.75rem;
763 overflow: hidden;
764}
765
766.folder-icon-grid {
767 display: grid;
768 grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
769 gap: 0.5rem;
770 max-height: 50vh;
771 overflow-y: auto;
772 padding: 0.25rem;
773 background: var(--bg);
774 border: 1px solid var(--border);
775 border-radius: var(--radius);
776}
777
778.folder-icon-filter {
779 width: 100%;
780 background: var(--bg);
781 border: 1px solid var(--border);
782 border-radius: 6px;
783 color: var(--text);
784 font-size: 0.9rem;
785 padding: 0.48rem 0.68rem;
786 outline: none;
787}
788
789.folder-icon-filter:focus {
790 border-color: var(--accent);
791}
792
793.folder-icon-cell {
794 display: flex;
795 flex-direction: column;
796 align-items: center;
797 gap: 0.3rem;
798 padding: 0.4rem;
799 border-radius: var(--radius);
800 border: 2px solid transparent;
801 cursor: pointer;
802 transition: border-color var(--transition), background var(--transition);
803}
804
805.folder-icon-cell:hover {
806 background: var(--surface2);
807}
808
809.folder-icon-cell.selected {
810 border-color: var(--accent);
811 background: rgba(91, 127, 255, 0.12);
812}
813
814.folder-icon-thumb {
815 width: 60px;
816 height: 60px;
817 object-fit: cover;
818 border-radius: 4px;
819 background: var(--surface2);
820}
821
822.folder-icon-label {
823 font-size: 0.68rem;
824 color: var(--text-muted);
825 word-break: break-all;
826 text-align: center;
827 max-width: 72px;
828 overflow: hidden;
829 display: -webkit-box;
830 -webkit-line-clamp: 2;
831 -webkit-box-orient: vertical;
832}
833
834.vjs-text-track-cue>div {
835 background: transparent !important;
836 text-shadow: 2px 0 black, -2px 0 black, 0 2px black, 0 -2px black,
837 1px 1px black, -1px -1px black, 1px -1px black, -1px 1px black;
838}
839
840/* Admin path list */
841.path-row {
842 display: flex;
843 align-items: center;
844 gap: 0.5rem;
845 padding: 0.4rem 0;
846 border-bottom: 1px solid var(--border);
847 font-size: 0.88rem;
848}
849
850.path-row span {
851 flex: 1;
852 word-break: break-all;
853}
854
855.path-row button {
856 background: none;
857 color: var(--danger);
858 padding: 0.2rem 0.5rem;
859}
860
861.path-add-row {
862 display: flex;
863 gap: 0.5rem;
864 margin: 0.5rem 0;
865}
866
867.path-add-row input {
868 flex: 1;
869 background: var(--bg);
870 border: 1px solid var(--border);
871 border-radius: 6px;
872 padding: 0.45rem 0.7rem;
873 color: var(--text);
874 font-size: 0.9rem;
875 outline: none;
876}
877
878.path-add-row input:focus {
879 border-color: var(--accent);
880}
881
882.path-add-row button {
883 background: var(--surface2);
884 color: var(--text);
885 padding: 0.45rem 0.9rem;
886}
887
888.path-add-row button:hover {
889 background: var(--border);
890}
891
892.admin-favicon-row {
893 display: flex;
894 align-items: center;
895 justify-content: space-between;
896 margin: 0.35rem 0 0.6rem;
897 font-size: 0.88rem;
898 color: var(--text-muted);
899}
900
901.admin-favicon-row .icon-btn {
902 color: var(--text);
903 background: var(--surface2);
904}
905
906.admin-favicon-row .icon-btn:hover {
907 background: var(--border);
908}
909
910/* User list */
911.user-row {
912 display: flex;
913 align-items: center;
914 gap: 0.6rem;
915 padding: 0.5rem 0;
916 border-bottom: 1px solid var(--border);
917}
918
919.user-row .user-name {
920 flex: 1;
921 font-weight: 600;
922 font-size: 0.9rem;
923}
924
925.user-row .user-admin-badge {
926 font-size: 0.72rem;
927 background: var(--accent);
928 color: #fff;
929 border-radius: 4px;
930 padding: 0.1rem 0.4rem;
931}
932
933.user-row button {
934 background: none;
935 color: var(--text-muted);
936 padding: 0.2rem 0.5rem;
937 font-size: 0.85rem;
938}
939
940.user-row button:hover {
941 color: var(--text);
942}
943
944.user-row button.danger {
945 color: var(--danger);
946}
947
948/* User form permissions */
949#user-permissions {
950 margin-top: 0.75rem;
951}
952
953#user-permissions h4 {
954 font-size: 0.85rem;
955 color: var(--text-muted);
956 margin-bottom: 0.4rem;
957}
958
959.perm-row {
960 display: flex;
961 align-items: center;
962 gap: 0.75rem;
963 flex-wrap: wrap;
964 font-size: 0.85rem;
965 margin-bottom: 0.4rem;
966}
967
968.perm-row .perm-label {
969 min-width: 130px;
970 color: var(--text);
971}
972
973.checkbox-label {
974 display: flex;
975 align-items: center;
976 gap: 0.5rem;
977 font-size: 0.9rem;
978 margin-bottom: 0.5rem;
979}
980
981.checkbox-label input[type="checkbox"] {
982 width: 16px;
983 height: 16px;
984 accent-color: var(--accent);
985}
986
987/* Form labels in modals */
988.modal form label {
989 display: flex;
990 flex-direction: column;
991 gap: 0.3rem;
992 font-size: 0.85rem;
993 color: var(--text-muted);
994 margin-bottom: 0.9rem;
995}
996
997.modal form input[type="text"],
998.modal form input[type="password"] {
999 background: var(--bg);
1000 border: 1px solid var(--border);
1001 border-radius: 6px;
1002 padding: 0.5rem 0.75rem;
1003 color: var(--text);
1004 font-size: 0.95rem;
1005 outline: none;
1006 transition: border-color var(--transition);
1007}
1008
1009.modal form input:focus {
1010 border-color: var(--accent);
1011}
1012
1013/* Admin user-folder controls use the same visual language as modal forms. */
1014#admin-userfolder-section label {
1015 display: flex;
1016 flex-direction: column;
1017 gap: 0.3rem;
1018 font-size: 0.85rem;
1019 color: var(--text-muted);
1020 margin-bottom: 0.9rem;
1021}
1022
1023#admin-userfolder-section input[type="text"] {
1024 background: var(--bg);
1025 border: 1px solid var(--border);
1026 border-radius: 6px;
1027 padding: 0.5rem 0.75rem;
1028 color: var(--text);
1029 font-size: 0.95rem;
1030 outline: none;
1031 transition: border-color var(--transition);
1032}
1033
1034#admin-userfolder-section input[type="text"]:focus {
1035 border-color: var(--accent);
1036}
1037
1038/* =========================================================
1039 FILE PREVIEW — SHARED MEDIA STYLES
1040 ========================================================= */
1041.preview-media {
1042 max-width: 100%;
1043 max-height: 100%;
1044 width: auto;
1045 height: auto;
1046 object-fit: contain;
1047}
1048
1049.preview-frame {
1050 width: 100%;
1051 height: 100%;
1052 border: none;
1053 border-radius: 8px;
1054 background: #fff;
1055}
1056
1057.preview-audio {
1058 width: min(640px, 95%);
1059}
1060
1061.preview-model-wrap {
1062 width: 100%;
1063 height: 100%;
1064 min-height: 240px;
1065 border: 1px solid var(--border);
1066 border-radius: 8px;
1067 background: #0d111a;
1068 display: flex;
1069 flex-direction: column;
1070 align-items: stretch;
1071 justify-content: stretch;
1072 overflow: hidden;
1073}
1074
1075.preview-model-canvas {
1076 flex: 1 1 auto;
1077 width: 100%;
1078 min-height: 180px;
1079 display: block;
1080 cursor: grab;
1081}
1082
1083.preview-model-canvas:active {
1084 cursor: grabbing;
1085}
1086
1087.preview-model-hint {
1088 margin: 0;
1089 padding: 0.45rem 0.7rem;
1090 border-top: 1px solid rgba(120, 128, 160, 0.35);
1091 color: #b8c4e8;
1092 font-size: 0.78rem;
1093 text-align: center;
1094}
1095
1096.preview-text {
1097 width: 100%;
1098 min-height: 100%;
1099 color: #dce4ff;
1100 background: #0d111a;
1101 border: 1px solid var(--border);
1102 border-radius: 8px;
1103 padding: 0.9rem;
1104 font: 0.85rem/1.45 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
1105 overflow: auto;
1106 white-space: pre;
1107 text-align: left;
1108}
1109
1110.preview-code .tok-comment {
1111 color: #6f7f9a;
1112}
1113
1114.preview-code .tok-string {
1115 color: #9ee37d;
1116}
1117
1118.preview-code .tok-number {
1119 color: #f8c46a;
1120}
1121
1122.preview-code .tok-keyword {
1123 color: #8bb4ff;
1124 font-weight: 600;
1125}
1126
1127.preview-code .tok-key {
1128 color: #59c8ff;
1129}
1130
1131.preview-unsupported {
1132 color: var(--text-muted);
1133 font-size: 0.95rem;
1134 max-width: 56ch;
1135 text-align: center;
1136}
1137
1138.preview-footer {
1139 border-top: 1px solid var(--border);
1140 padding: 0.8rem 1rem;
1141 display: flex;
1142 justify-content: flex-end;
1143}
1144
1145.preview-footer .primary {
1146 width: auto;
1147 margin-top: 0;
1148 min-width: 8rem;
1149}
1150
1151
1152
1153/* =========================================================
1154
1155.toast-msg {
1156 background: var(--surface2);
1157 border: 1px solid var(--border);
1158 border-radius: 8px;
1159 padding: 0.6rem 1.25rem;
1160 font-size: 0.9rem;
1161 animation: slideup 0.25s ease;
1162}
1163
1164.toast-msg.err {
1165 border-color: var(--danger);
1166 color: var(--danger);
1167}
1168
1169.toast-msg.ok {
1170 border-color: var(--success);
1171 color: var(--success);
1172}
1173
1174@keyframes slideup {
1175 from {
1176 opacity: 0;
1177 transform: translateY(12px);
1178 }
1179
1180 to {
1181 opacity: 1;
1182 transform: translateY(0);
1183 }
1184}
1185
1186/* =========================================================
1187 UPLOAD PROGRESS
1188 ========================================================= */
1189.upload-bar-wrap {
1190 position: fixed;
1191 bottom: 0;
1192 left: 0;
1193 right: 0;
1194 background: var(--surface);
1195 border-top: 1px solid var(--border);
1196 padding: 0.5rem 1rem;
1197 z-index: 80;
1198 font-size: 0.85rem;
1199}
1200
1201.upload-bar-track {
1202 height: 6px;
1203 background: var(--border);
1204 border-radius: 3px;
1205 margin-top: 0.3rem;
1206}
1207
1208.upload-bar-fill {
1209 height: 100%;
1210 background: var(--accent);
1211 border-radius: 3px;
1212 transition: width 0.2s linear;
1213}
1214
1215/* =========================================================
1216 RESPONSIVE — narrow screens
1217 ========================================================= */
1218@media (max-width: 600px) {
1219 #topbar {
1220 height: auto;
1221 min-height: var(--topbar-h);
1222 padding: 0.5rem 0.6rem;
1223 align-items: flex-start;
1224 flex-direction: column;
1225 }
1226
1227 #topbar > #btn-refresh {
1228 align-self: flex-start;
1229 }
1230
1231 #breadcrumb-wrap {
1232 width: 100%;
1233 }
1234
1235 #topbar-actions {
1236 width: 100%;
1237 flex-wrap: wrap;
1238 gap: 0.15rem;
1239 }
1240
1241 .top-search {
1242 order: -1;
1243 width: 100%;
1244 margin-right: 0;
1245 }
1246
1247 .top-search input {
1248 flex: 1;
1249 min-width: 0;
1250 width: auto;
1251 }
1252
1253 .topbar-dropdown-menu {
1254 position: fixed;
1255 top: calc(var(--topbar-h) + 0.35rem);
1256 left: 0.6rem;
1257 right: 0.6rem;
1258 min-width: 0;
1259 }
1260
1261 .topbar-dropdown-menu--right {
1262 left: 0.6rem;
1263 right: 0.6rem;
1264 }
1265
1266 .icon-btn {
1267 padding: 0.4rem 0.55rem;
1268 font-size: 0.82rem;
1269 }
1270
1271 #main-content {
1272 padding: 0.9rem;
1273 }
1274
1275 #file-grid {
1276 grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
1277 }
1278
1279 #app.sidebar-open #main-content {
1280 margin-right: 0;
1281 }
1282
1283 #sidebar {
1284 top: auto;
1285 right: 0;
1286 bottom: 0;
1287 left: 0;
1288 height: auto;
1289 max-height: min(68vh, calc(100vh - 0.5rem));
1290 padding: 0.9rem 0.9rem 1rem;
1291 border-left: none;
1292 border-top: 1px solid var(--border);
1293 width: 100%;
1294 border-radius: 14px 14px 0 0;
1295 box-shadow: 0 -12px 26px rgba(0, 0, 0, 0.34);
1296 gap: 0.55rem;
1297 }
1298
1299 #sidebar-close {
1300 display: inline-flex;
1301 position: absolute;
1302 top: 0.45rem;
1303 right: 0.45rem;
1304 border-color: var(--border);
1305 background: var(--surface2);
1306 }
1307
1308 #sidebar-name {
1309 padding-right: 2rem;
1310 }
1311
1312 #sidebar-icon svg {
1313 width: 54px;
1314 height: 54px;
1315 }
1316
1317 #sidebar-actions {
1318 margin-top: 0.2rem;
1319 }
1320
1321 .modal {
1322 padding: 1.25rem;
1323 }
1324
1325 .preview-overlay {
1326 padding: 0.8rem;
1327 }
1328
1329 .preview-sheet {
1330 width: 100%;
1331 height: 92vh;
1332 }
1333
1334 .preview-fold {
1335 width: 54px;
1336 height: 54px;
1337 }
1338
1339 .preview-close {
1340 top: 5px;
1341 right: 5px;
1342 }
1343}
1344
1345/* =========================================================
1346 DIALOG MODALS (confirm / prompt / overwrite)
1347 ========================================================= */
1348.dialog-message {
1349 color: var(--text-muted);
1350 font-size: 0.93rem;
1351 margin: 0 0 1.5rem;
1352 line-height: 1.5;
1353 word-break: break-word;
1354}
1355
1356.dialog-actions {
1357 display: flex;
1358 gap: 0.6rem;
1359 justify-content: flex-end;
1360 flex-wrap: wrap;
1361}
1362
1363.dialog-actions--overwrite {
1364 justify-content: space-between;
1365}
1366
1367.dialog-actions button {
1368 min-width: 5rem;
1369 background: var(--surface2);
1370 color: var(--text);
1371 padding: 0.5rem 1rem;
1372}
1373
1374.dialog-actions button:hover {
1375 background: var(--border);
1376}
1377
1378/* Override .primary full-width inside dialog rows */
1379.dialog-actions button.primary {
1380 width: auto;
1381 margin-top: 0;
1382}