-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathappetizers.css
More file actions
749 lines (603 loc) · 12.6 KB
/
appetizers.css
File metadata and controls
749 lines (603 loc) · 12.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
/* ================================
Appetizers Page CSS
僅負責前菜頁格式,不改內容
================================ */
/* ---------- 全域設定 ---------- */
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
html, body {
overflow-x: hidden; /* 禁止左右晃動 */
font-family: "Noto Sans TC", Arial, sans-serif;
background-color: #f5f5f5;
color: #333;
}
.top-nav img {
height: 90px; /* 左圖大小 */
width: auto;
}
#sidebar.collapsed ~ header .top-nav {
left: 70px;
}
/* ====== Top Navigation(沿用原本風格)====== */
.page-header {
margin-top: 0;
}
.top-nav {
position: fixed;
top: 0;
left: 0;
right: 0;
display: flex;
align-items: center;
justify-content: space-between; /* ⭐ 左右兩邊分開 */
padding-left: 252px; /* sidebar 寬 + margin */
padding-right: 32px; /* 右側空間 */
height: 90px;
background: rgba(255, 255, 255, 0.35);
backdrop-filter: blur(14px);
z-index: 50;
}
.top-nav.show {
opacity: 1;
pointer-events: auto;
}
.nav-left {
display: flex;
align-items: center;
gap: 24px;
}
.nav-right {
display: flex;
align-items: center;
gap: 16px;
/* ❌ 刪掉 position absolute / top / right */
}
.top-nav a {
color: #2c2c2c;
font-weight: 700;
text-shadow: 0 1px 2px rgba(255,255,255,0.6);
font-family: "Noto Serif TC", "思源宋體", serif;
font-weight: 700; /* ⭐ 加粗 */
display: flex;
align-items: center;
gap: 6px;
color: #333;
text-decoration: none;
font-size: 15px;
}
.top-nav {
z-index: 50;
}
.logo-link {
position: static; /* ⭐ 不要讓 a 撐版 */
}
.logo-center {
position: absolute;
left: 58%;
top: 42%; /* 對齊 nav 高度 */
transform: translate(-50%, -50%);
pointer-events: auto;
width: 30px;
height: 30px;
background: rgba(255,255,255,0.75);
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
}
.logo-center img {
width: 80px;
height: auto;
}
.top-nav1 {
width: 40px!important; /* 想大就改這裡:22 / 24 / 26 */
height: 40px!important;
object-fit: contain;
vertical-align: middle;
}
.top-nav a {
gap: 0px; /* icon 跟文字距離 */
}
/* ---------- 左側導覽列 ---------- */
/* ---------- 左側導覽列 ---------- */
#sideMenu {
position: fixed;
top: 0;
left: 0;
width: 220px;
height: 100vh;
overflow: hidden; /* 防止整個 sidebar 捲動 */
background: linear-gradient(135deg, #2c3e50, #34495e);
display: flex;
flex-direction: column;
align-items: stretch; /* 塞滿整個寬度 */
padding-top: 0px; /* 避開最上方 */
z-index: 60;
}
/* 導覽列清單 */
.menu-icon {
width: 80px;
height: 80px;
object-fit: contain;
/*outline: 1px solid red;
background: rgba(255,0,0,0.15);/*測試icon*/
/* 關鍵:不要再套任何 filter */
/*filter: none !important;*/
}
.menu-icon {
background-color: transparent;
}
#sideMenu nav {
flex: 1;
height: 80%;
/* overflow-y: auto; ⭐ 清單自己滾 */
}
/*#sideMenu nav {
}*/
#sideMenu nav ul {
display: flex;
flex-direction: column;
/*justify-content: space-between; /* ⭐ 真平均 */
justify-content: flex-start; /* ⭐ 關鍵:全部往上排 */
height: auto; /* ⭐ 不撐滿 */
list-style: none;
padding: 20px 0;
margin: 0;
gap: 0px;
padding-bottom: 100px ; /* 給最後一個一點空間 */
/*height: 100%;*/
}
/* 每個項目 li */
#sideMenu nav ul li {
width: 90%;
}
/* 每個連結 a */
#sideMenu nav ul li a {
display: flex;
align-items: center;
gap: 12px;
padding: 10px 20px;
color: #ffffff !important; /* 永遠白色 */
font-size: 16px;
text-decoration: none;
}
aside#sideMenu a .menu-text {
color: #f5f6f8;
}
/* 文字 span */
#sideMenu nav ul li a .menu-text {
color: #ffffff !important;
}
/* hover 不改顏色 */
#sideMenu nav ul li a,
#sideMenu nav ul li a .menu-text {
color: #ffffff !important; /* 強制白色,不受其他規則影響 */
}
/*#sideMenu nav ul li a:hover .menu-icon {
fill: #ffffff;
}/* 左側導覽列 icon 固定大小46C2AC */
/* 左側導覽列 icon 固定大小 */
#sideMenu img.menu-icon {
width: auto; /* 寬度自動 */
height: 1.8em; /* ⭐ 跟字一樣高 */
margin-right: 0px; /* icon 跟文字距離 */
vertical-align: middle;
filter: brightness(0) invert(1);
/*object-fit: contain;
background: transparent;
filter: none !important;*/
}
#sideMenu > img.menu-icon {
width: 24px;
height: 24px;
margin: 0 auto 8px;
}
/* 左側導覽列 hover 顏色 */
#sideMenu nav ul li a:hover {
color: #46C2AC;
}
/* 左側收合狀態 */
#sideMenu.collapsed {
width: 64px; /* 只顯示 icon */
}
#sideMenu.collapsed nav ul li a {
justify-content: space-between;
height: 100%; /* 撐滿側邊欄 */
gap: 0;
}
#sideMenu.collapsed nav ul li a .menu-text {
display: none;
}
#sideMenu.collapsed nav ul li a img.menu-icon {
margin: 0 auto;
display: block;
}
/* 不做 hover 動畫,避免亂跳 */
aside.menu-open nav ul li a:hover {
color: #46C2AC;
background: none;
}
/* 縮 */
.menu-label {
opacity: 0;
width: 0;
overflow: hidden;
transition: .3s;
}
#sideMenu.collapsed ~ header .menu-label {
opacity: 1;
width: auto;
}
/* 左側選單:收合狀態(只剩 icon) */
#sideMenu.collapsed {
width: 64px; /* 剛好塞下 icon */
background: linear-gradient(135deg, #2c3e50, #34495e);
}
#sideMenu.collapsed nav ul li a {
justify-content: center;
gap: 0;
}
#sideMenu.collapsed img.menu-icon {
margin: 0 auto;
display: block;
}
/* 只藏文字 */
#sideMenu.collapsed .menu-text {
opacity: 0;
width: 0;
overflow: hidden;
}
#sideMenu.collapsed nav ul li a span,
#sideMenu.collapsed nav ul li a img {
font-size: initial;
}
/* 三條線那一列 */
.menu-toggle-item {
display: flex;
justify-content: center; /* 水平置中 */
align-items: center; /* 垂直置中 */
padding: 12px 0;
}
.menu-toggle {
background: transparent; /* 不要白底 */
border: none; /* 不要外框 */
color: #ffffff; /* 跟 icon 一樣白 */
font-size: 20px; /* 三條線大小 */
cursor: pointer;
width: 40px;
height: 40px;
display: flex;
align-items: center;
justify-content: center;
}
.menu-toggle:hover {
background: rgba(255,255,255,0.08);
border-radius: 6px;
}
#sideMenu.collapsed .menu-toggle-item {
justify-content: center;
}
#menuHint {
position: fixed;
top: 30px;
left: 80px;
z-index: 2000;
/*background: rgba(44, 62, 80, 0.85);*/
background: rgba(255, 255, 255, 0.35);
backdrop-filter: blur(12px);
-webkit-backdrop-filter: blur(12px);
/* 外框微微提亮,不是黑框 */
border: 1px solid rgba(255, 255, 255, 0.35);
color: #fff;
border: none;
border-radius: 6px;
padding: 6px 12px;
font-size: 14px;
cursor: pointer;
display: none; /* 預設不顯示 */
}
#menuHint:hover {
background: rgba(255, 255, 255, 0.35);
}
#menuHint {
appearance: none;
-webkit-appearance: none;
border: 1px solid rgba(255, 255, 255, 0.35);
}
#menuHint,
#menuHint:hover,
#menuHint:active,
#menuHint:focus,
#menuHint:focus-visible {
background: rgba(255, 255, 255, 0.18);
backdrop-filter: blur(12px);
-webkit-backdrop-filter: blur(12px);
color: #1f2d3d;
border: 1px solid rgba(255, 255, 255, 0.35);
box-shadow: none;
outline: none;
}
/* ---------- Header ---------- */
.header {
margin-left: 220px;
}
.header-banner {
width: 100%;
height: 250px;
object-fit: cover;
display: block; /* 避免 inline img 留縫 */
margin-top: 0;
}
.header-controls {
position: absolute;
top: 16px;
right: 24px;
display: flex;
align-items: center;
gap: 14px;
z-index: 40;
}
/* 音樂播放器與語言切換 */
.music-player {
padding: 10px 20px;
}
.language-switch {
position: relative;
}
#langBtn {
background: #f5f5f5;
color: #0e0101;
border: none;
padding: 6px 12px;
cursor: pointer;
border-radius: 4px;
}
#langMenu {
display: none;
position: absolute;
top: 110%;
right: 0;
background: white;
list-style: none;
border-radius: 4px;
box-shadow: 0 2px 6px rgba(0,0,0,.2);
}
#langMenu li {
padding: 6px 12px;
cursor: pointer;
}
.language-switch {
display: flex;
gap: 8px;
}
.language-switch button {
background: #46C2AC;
color: #fff;
border: none;
padding: 5px 10px;
border-radius: 4px;
cursor: pointer;
}
.music-player audio {
height: 32px;
}
/* ---------- 主要內容區 ---------- */
.container {
margin-left: 220px;
padding: 40px 30px;
padding-top: calc(40px + 45px); /* ⭐ 關鍵 */
}
/* 主標:前菜 */
.article-h1 {
font-family: "辰宇落雁體", cursive;
font-size: 1.6rem; /* 與左邊一致 */
color: #46C2AC;
margin-bottom: 10px;
}
/* 副標說明文字 */
.article-subtitle,
article .content p {
font-family: "Noto Serif TC", "思源宋體", serif;
font-size: 1.1rem;
color: #3835B0;
line-height: 1.8;
}
body,
.description p,
.price-placeholder,
footer,
article p {
font-family: "Noto Serif TC", "思源宋體", serif;
}
/* 內容說明文字 */
.content p {
margin-bottom: 40px;
font-size: 16px;
}
/* ---------- 商品區(卡片結構) ---------- */
.section1-list {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
gap: 30px;
}
.section1 {
background-color: #ffffff;
border-radius: 10px;
padding: 20px;
}
.product-name {
font-family: "辰宇落雁體", cursive;
font-size: 20px;
margin-bottom: 1.25rem;
color: #D6AE72;
font-weight: normal;
}
.section1-img {
width: 100%;
height: 180px;
object-fit: cover;
border-radius: 6px;
}
.dashed-line {
margin: 12px 0;
border: none;
border-top: 1px dashed #ccc;
}
.currency {
font-size: 0.8em;
}/*價格後的小價格顯示*/
.price-placeholder {
display: block;
font-weight: bold;
color: #46C2AC;
margin-bottom: 10px;
}
.description p {
font-size: 14px;
line-height: 1.6;
}
/* Footer */
footer {
margin-left: 0px;
background: #2c3e50;
}
.footer-inner {
max-width: calc(100% - 0px);
padding: 20px 30px;
display: flex;
justify-content: space-between;
align-items: center;
color: white;
margin-left: 220px; /* 內容對齊 */
}
#sidebar.collapsed ~ footer {
margin-left: 60px;
}
footer a {
color: white;
text-decoration: none;
font-size: 1.1rem;
}
.social {
display: flex;
gap: 15px;
}
.social a {
font-size: 1.5rem;
transition: color 0.3s;
}
.social a:hover {
color: #3498db;
}
/* 響應式設計 */
@media (max-width: 768px) {
.section1 {
flex: 1 1 100%;
max-width: 100%;
}
#sidebar {
width: 60px;
}
header, main, footer {
margin-left: 60px;
}
}
/* 📱 手機版強制歸位(不改原設計) */
@media (max-width: 768px) {
body {
margin-left: 4 !important;
padding-left: 0 !important;
transform: none !important;
}
/* 所有主要容器一起拉回左邊 */
.container,
.main,
.content,
.page,
.wrapper,
.footer-inner {
/* margin-left: 0 !important;*/
/* padding-left: 0 !important;*/
left: 6 !important;
transform: none !important;
margin-left: 30px; /* 跟 sidebar 寬度一致 */
padding-left: 12px; /* 再補一點呼吸感 */
}
}
/* 手機版 */
@media (max-width: 768px) {
.sidebar {
width: 56px; /* icon 寬度 */
min-width: 56px;
}
.sidebar .menu-text {
display: none; /* 隱藏文字 */
}
#menuHint {
display: none;
}
/* ====== Top Nav 改成兩行 ====== */
.top-nav {
top: 0;
height: auto;
padding: 8px 12px 8px 56px; /* 對齊 sidebar */
display: flex;
flex-direction: column;
gap: 6px;
}
/* LOGO 單獨一行、置中 */
.logo-center {
position: static; /* ⭐ 不要 absolute */
transform: none;
display: flex;
justify-content: center;
order: 4px;
}
.logo-center img {
width: 60px;
height: auto;
}
.music-player {
width: 100%;
}
.music-player audio {
width: 100%;
}
/* 右側 icon 一行 */
.nav-right {
order: 2;
display: flex;
justify-content: flex-end;
gap: 8px;
}
/* 左側文字選單 → 第二行橫向滑動 */
.nav-left {
order: 3;
display: flex;
gap: 12px;
overflow-x: auto;
white-space: nowrap;
padding: 4px 0;
}
.nav-left a {
flex-shrink: 0;
font-size: 14px;
}
.lang-full {
display: none;
}
.lang-short {
display: inline;
font-weight: 700;
}
#langBtn {
padding: 6px 10px;
font-size: 14px;
}
}
.lang-short {
display: none;
}