@ecl/mega-menu 5.0.0-alpha.2 → 5.0.0-alpha.20

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/mega-menu.scss CHANGED
@@ -12,9 +12,48 @@
12
12
  $theme: null !default;
13
13
  $mega-menu: null !default;
14
14
 
15
+ :root {
16
+ --ecl-mega-menu-item-promotional-bg: #{map.get(
17
+ $mega-menu,
18
+ 'global',
19
+ 'promotional-item-bg'
20
+ )};
21
+ --ecl-mega-menu-item-promotional-hover-bg: #{map.get(
22
+ $mega-menu,
23
+ 'global',
24
+ 'promotional-item-bg-hover'
25
+ )};
26
+ --ecl-mega-menu-item-promotional-focus-bg: #{map.get(
27
+ $mega-menu,
28
+ 'global',
29
+ 'promotional-item-bg-focus'
30
+ )};
31
+ --ecl-mega-menu-item-promotional-outline-color: #{map.get(
32
+ $mega-menu,
33
+ 'global',
34
+ 'promotional-item-outline-color'
35
+ )};
36
+ --ecl-mega-menu-item-promotional-text-color: #{map.get(
37
+ $mega-menu,
38
+ 'global',
39
+ 'promotional-item-text-color'
40
+ )};
41
+ --ecl-mega-menu-item-promotional-hover-text-color: #{map.get(
42
+ $mega-menu,
43
+ 'global',
44
+ 'promotional-item-hover-text-color'
45
+ )};
46
+ --ecl-mega-menu-item-promotional-focus-text-color: #{map.get(
47
+ $mega-menu,
48
+ 'global',
49
+ 'promotional-item-focus-text-color'
50
+ )};
51
+ }
52
+
15
53
  @mixin with-scrollbar {
16
54
  overflow-y: auto;
17
- scrollbar-color: var(--c-n) rgba(0, 0, 0, 0);
55
+ scrollbar-color: var(--cm-on-surface-neutral-medium, var(--c-n))
56
+ rgb(0, 0, 0, 0);
18
57
  scrollbar-width: thin;
19
58
  }
20
59
 
@@ -54,7 +93,7 @@ $mega-menu: null !default;
54
93
  display: flex;
55
94
  flex-direction: column;
56
95
  font: var(--f-xs);
57
- margin-inline-start: var(--s-xs);
96
+ margin-inline-start: map.get($mega-menu, 'mobile', 'open-button-margin');
58
97
  order: 2;
59
98
  padding: map.get($mega-menu, 'mobile', 'open-padding');
60
99
  text-decoration: none;
@@ -68,11 +107,12 @@ $mega-menu: null !default;
68
107
  }
69
108
 
70
109
  &:hover {
110
+ background-color: map.get($mega-menu, 'mobile', 'open-background-hover');
71
111
  text-decoration: underline;
72
112
  }
73
113
 
74
114
  &:focus-visible {
75
- outline-offset: -2px;
115
+ outline-offset: map.get($mega-menu, 'mobile', 'open-button-offset');
76
116
  }
77
117
 
78
118
  .ecl-icon:last-of-type {
@@ -80,9 +120,13 @@ $mega-menu: null !default;
80
120
  }
81
121
  }
82
122
 
83
- .ecl-mega-menu[aria-expanded='true'] .ecl-mega-menu__open {
123
+ .ecl-mega-menu[data-expanded] .ecl-mega-menu__open {
84
124
  background-color: map.get($mega-menu, 'mobile', 'open-background-active');
85
125
 
126
+ &:hover {
127
+ background-color: map.get($mega-menu, 'mobile', 'open-background-hover');
128
+ }
129
+
86
130
  .ecl-icon:first-of-type {
87
131
  display: none;
88
132
  }
@@ -107,14 +151,14 @@ $mega-menu: null !default;
107
151
  }
108
152
 
109
153
  /* stylelint-disable-next-line order/order */
110
- @include breakpoints.up('l') {
154
+ @include breakpoints.up('xl') {
111
155
  .ecl-mega-menu:not(.ecl-menu--forced-mobile) {
112
156
  background: map.get($mega-menu, 'desktop', 'menu-background');
113
157
  padding-bottom: 0;
114
158
  padding-top: 0;
115
159
 
116
160
  .ecl-container {
117
- padding: 0 var(--s-m);
161
+ padding: 0 map.get($mega-menu, 'desktop', 'container-padding-horizontal');
118
162
  }
119
163
 
120
164
  .ecl-mega-menu__container {
@@ -164,7 +208,7 @@ $mega-menu: null !default;
164
208
  }
165
209
 
166
210
  // Expanded
167
- .ecl-mega-menu[aria-expanded='true'] .ecl-mega-menu__inner {
211
+ .ecl-mega-menu[data-expanded] .ecl-mega-menu__inner {
168
212
  display: block;
169
213
  right: 0;
170
214
  }
@@ -177,6 +221,7 @@ $mega-menu: null !default;
177
221
  display: flex;
178
222
  flex-flow: row-reverse;
179
223
  height: map.get($mega-menu, 'mobile', 'header-height');
224
+ padding-block-end: var(--s-xs);
180
225
  }
181
226
 
182
227
  .ecl-mega-menu__title {
@@ -275,8 +320,7 @@ $mega-menu: null !default;
275
320
  z-index: -1;
276
321
  }
277
322
 
278
- .ecl-mega-menu[aria-expanded='true'],
279
- .ecl-mega-menu[data-expanded='true'] {
323
+ .ecl-mega-menu[data-expanded] {
280
324
  .ecl-mega-menu__overlay {
281
325
  display: block;
282
326
  }
@@ -290,7 +334,7 @@ $mega-menu: null !default;
290
334
  }
291
335
 
292
336
  /* stylelint-disable-next-line order/order */
293
- @include breakpoints.up('l') {
337
+ @include breakpoints.up('xl') {
294
338
  .ecl-mega-menu:not(.ecl-menu--forced-mobile) {
295
339
  .ecl-mega-menu__overlay {
296
340
  background-color: map.get($mega-menu, 'desktop', 'overlay-background');
@@ -301,7 +345,6 @@ $mega-menu: null !default;
301
345
  background-color: transparent;
302
346
  box-shadow: none;
303
347
  display: block;
304
- margin-inline-start: calc(-1 * var(--s-m));
305
348
  overflow-y: visible;
306
349
  position: static;
307
350
  transition: none;
@@ -316,14 +359,15 @@ $mega-menu: null !default;
316
359
  }
317
360
 
318
361
  .ecl-mega-menu__wrapper {
319
- background: map.get($theme, 'color', 'white');
362
+ background: #fff;
320
363
  display: none;
364
+ font: map.get($mega-menu, 'global', 'font');
321
365
  position: absolute;
322
366
  height: 100%;
323
367
  left: 0;
324
368
  padding: 0;
325
369
  top: 0;
326
- width: calc(100vw - var(--s-m));
370
+ width: 100%;
327
371
  }
328
372
 
329
373
  /*
@@ -347,6 +391,11 @@ $mega-menu: null !default;
347
391
  .ecl-mega-menu__inner--expanded & {
348
392
  margin-top: 0;
349
393
  }
394
+
395
+ .ecl-mega-menu--one-panel &,
396
+ .ecl-mega-menu--two-panels & {
397
+ margin-inline: 0;
398
+ }
350
399
  }
351
400
 
352
401
  .ecl-mega-menu__item {
@@ -358,15 +407,18 @@ $mega-menu: null !default;
358
407
  .ecl-mega-menu__featured-list__item .ecl-link {
359
408
  align-items: center;
360
409
  background: transparent;
410
+ /* stylelint-disable-next-line declaration-property-value-no-unknown */
361
411
  border-bottom: 1px solid
362
412
  map.get($mega-menu, 'desktop', 'sublink-current-background');
363
413
  border-radius: 0;
364
414
  box-sizing: border-box;
365
415
  color: map.get($mega-menu, 'mobile', 'item-color');
366
416
  display: inline-flex;
417
+ font: map.get($mega-menu, 'global', 'font');
367
418
  line-height: map.get($theme, 'line-height-ui', 'xs');
368
419
  padding: map.get($mega-menu, 'mobile', 'item-padding');
369
420
  position: relative;
421
+ text-align: start;
370
422
  width: 100%;
371
423
 
372
424
  > span {
@@ -392,8 +444,8 @@ $mega-menu: null !default;
392
444
  background: transparent;
393
445
  border-color: transparent;
394
446
  border-radius: 0px;
395
- color: var(--c-d);
396
- outline-color: var(--c-p);
447
+ color: var(--cm-on-surface-brand, var(--c-d));
448
+ outline-color: var(--cm-border-primary, var(--c-p));
397
449
  outline-offset: -2px;
398
450
  outline-width: 2px;
399
451
  }
@@ -413,11 +465,42 @@ $mega-menu: null !default;
413
465
  }
414
466
  }
415
467
 
416
- .ecl-mega-menu__featured-list__item .ecl-link {
417
- border-bottom: 1px solid map.get($mega-menu, 'mobile', 'featured-link-border');
468
+ .ecl-mega-menu__item--promotional .ecl-mega-menu__link {
469
+ background: var(--ecl-mega-menu-item-promotional-bg);
470
+ color: var(--ecl-mega-menu-item-promotional-text-color);
418
471
 
419
472
  &:hover {
420
- border-color: map.get($mega-menu, 'mobile', 'featured-link-border');
473
+ background: var(--ecl-mega-menu-item-promotional-hover-bg);
474
+ color: var(--ecl-mega-menu-item-promotional-hover-text-color);
475
+ }
476
+
477
+ &:focus-visible {
478
+ background: var(--ecl-mega-menu-item-promotional-focus-bg);
479
+ color: var(--ecl-mega-menu-item-promotional-focus-text-color);
480
+ outline-color: var(--ecl-mega-menu-item-promotional-outline-color);
481
+ outline-offset: -4px;
482
+ }
483
+ }
484
+
485
+ .ecl-mega-menu__featured-list__item {
486
+ .ecl-link {
487
+ .ecl-picture {
488
+ margin-inline: calc(-1 * var(--s-s)) 0;
489
+ }
490
+ }
491
+
492
+ &--combo .ecl-mega-menu__featured-image {
493
+ margin-block-end: var(--s-xs);
494
+ }
495
+
496
+ .ecl-mega-menu__featured-list__item-description {
497
+ margin-inline-start: var(--s-l);
498
+ }
499
+
500
+ .ecl-mega-menu__featured-list__item-description,
501
+ .ecl-mega-menu__featured-list__item-description p {
502
+ font: map.get($mega-menu, 'global', 'featured-description-font');
503
+ margin-block: 0;
421
504
  }
422
505
  }
423
506
 
@@ -428,17 +511,15 @@ $mega-menu: null !default;
428
511
  .ecl-mega-menu__sublink.ecl-mega-menu__parent-link {
429
512
  border: none;
430
513
  box-sizing: border-box;
431
- margin-inline-start: calc(-1 * var(--s-xs));
432
514
  padding-bottom: var(--s-xs);
433
515
  padding-inline-start: 1.75rem;
434
516
  padding-top: var(--s-xs);
435
- width: calc(100% + var(--s-m));
436
517
 
437
518
  &:focus-visible {
438
519
  outline: none;
439
520
 
440
521
  .ecl-button__label {
441
- outline: 2px solid var(--c-p);
522
+ outline: 2px solid var(--cm-border-primary, var(--c-p));
442
523
  outline-offset: 4px;
443
524
  }
444
525
  }
@@ -457,7 +538,7 @@ $mega-menu: null !default;
457
538
  .ecl-mega-menu__info {
458
539
  background: map.get($mega-menu, 'global', 'greysh-background');
459
540
  box-sizing: content-box;
460
- margin: 0 calc(-1 * var(--s-xs)) var(--s-m);
541
+ margin: 0 0 var(--s-m) 0;
461
542
  padding-inline-start: 1.75rem;
462
543
  padding-bottom: var(--s-2xl);
463
544
  padding-inline-end: 1.75rem;
@@ -468,37 +549,22 @@ $mega-menu: null !default;
468
549
  }
469
550
 
470
551
  .ecl-mega-menu__info-content {
471
- font: var(--f-m);
472
552
  max-width: var(--max-w);
473
553
  }
474
554
  }
475
555
 
476
- .ecl-mega-menu__info-link {
477
- border-bottom: 1px solid transparent;
478
- display: inline-block;
479
- width: fit-content;
480
-
481
- &:hover {
482
- text-decoration: underline !important;
483
- }
484
-
485
- &:focus-visible {
486
- border-radius: 0;
487
- }
488
-
489
- .ecl-mega-menu__info-content + & {
490
- margin-top: var(--s-xs);
556
+ .ecl-mega-menu__subitem {
557
+ .ecl-button__label {
558
+ margin-inline-end: var(--s-m);
491
559
  }
492
- }
493
560
 
494
- .ecl-mega-menu__subitem {
495
561
  .ecl-mega-menu__sublink--level-2 {
496
562
  background: transparent;
497
- color: var(--c-p);
563
+ color: var(--cm-on-surface-primary, var(--c-p));
498
564
 
499
565
  &:hover {
500
566
  box-shadow: none;
501
- color: var(--c-p-140);
567
+ color: var(--cm-on-surface-primary-highest, var(--c-p-140));
502
568
  }
503
569
  }
504
570
  }
@@ -510,12 +576,13 @@ $mega-menu: null !default;
510
576
  }
511
577
 
512
578
  /* stylelint-disable-next-line order/order */
513
- @include breakpoints.up('l') {
579
+ @include breakpoints.up('xl') {
514
580
  .ecl-mega-menu:not(.ecl-menu--forced-mobile) {
515
581
  border-top: map.get($mega-menu, 'desktop', 'menu-border');
516
582
 
517
583
  .ecl-mega-menu__inner {
518
584
  border-top: none;
585
+ margin-inline-start: calc(-1 * var(--s-xs));
519
586
  }
520
587
 
521
588
  .ecl-mega-menu__list {
@@ -553,7 +620,6 @@ $mega-menu: null !default;
553
620
  border-radius: 0;
554
621
  color: map.get($mega-menu, 'desktop', 'item-color');
555
622
  display: inline-flex;
556
- font: var(--f-m);
557
623
  height: 100%;
558
624
  line-height: map.get($mega-menu, 'desktop', 'link-line-height');
559
625
  padding: map.get($mega-menu, 'desktop', 'link-padding');
@@ -561,7 +627,7 @@ $mega-menu: null !default;
561
627
  z-index: 0;
562
628
 
563
629
  &:active {
564
- color: map.get($theme, 'color', 'white');
630
+ color: #fff;
565
631
  }
566
632
 
567
633
  &:hover {
@@ -579,12 +645,28 @@ $mega-menu: null !default;
579
645
  );
580
646
  border-radius: 0;
581
647
  color: map.get($mega-menu, 'desktop', 'item-color-focus');
582
- outline-color: map.get($theme, 'color', 'white');
583
- outline-offset: -8px;
648
+ outline-color: #fff;
649
+ outline-offset: map.get($mega-menu, 'desktop', 'outline-offset');
584
650
  outline-width: map.get($mega-menu, 'desktop', 'outline-width');
585
651
  }
586
652
  }
587
653
 
654
+ .ecl-mega-menu__item--promotional .ecl-mega-menu__link {
655
+ background: var(--ecl-mega-menu-item-promotional-bg);
656
+ color: var(--ecl-mega-menu-item-promotional-text-color);
657
+
658
+ &:hover {
659
+ background: var(--ecl-mega-menu-item-promotional-hover-bg);
660
+ color: var(--ecl-mega-menu-item-promotional-hover-text-color);
661
+ }
662
+
663
+ &:focus-visible {
664
+ background: var(--ecl-mega-menu-item-promotional-focus-bg);
665
+ color: var(--ecl-mega-menu-item-promotional-focus-text-color);
666
+ outline-color: var(--ecl-mega-menu-item-promotional-outline-color);
667
+ }
668
+ }
669
+
588
670
  .ecl-mega-menu__sublink {
589
671
  border-bottom: none;
590
672
  }
@@ -612,6 +694,10 @@ $mega-menu: null !default;
612
694
  }
613
695
  }
614
696
 
697
+ .ecl-mega-menu__featured-list__item-description {
698
+ margin-inline-start: var(--s-s);
699
+ }
700
+
615
701
  .ecl-mega-menu__item--current {
616
702
  background-color: map.get(
617
703
  $mega-menu,
@@ -635,15 +721,15 @@ $mega-menu: null !default;
635
721
  }
636
722
 
637
723
  .ecl-mega-menu__link:focus-visible {
638
- outline-color: var(--c-p);
724
+ outline-color: var(--cm-border-primary, var(--c-p));
639
725
  }
640
726
  }
641
727
  }
642
728
 
643
729
  .ecl-mega-menu:not(
644
- .ecl-mega-menu--forced-mobile,
645
- .ecl-mega-menu--forced-close
646
- ) {
730
+ .ecl-mega-menu--forced-mobile,
731
+ .ecl-mega-menu--forced-close
732
+ ) {
647
733
  .ecl-mega-menu__item {
648
734
  &.ecl-mega-menu__item--expanded > .ecl-button .ecl-icon {
649
735
  transform: rotate(0);
@@ -651,8 +737,8 @@ $mega-menu: null !default;
651
737
 
652
738
  &.ecl-mega-menu__item--expanded {
653
739
  .ecl-mega-menu__link {
654
- background-color: map.get($theme, 'color', 'white');
655
- color: var(--c-d);
740
+ background-color: #fff;
741
+ color: var(--cm-on-surface-brand, var(--c-d));
656
742
  z-index: map.get($theme, 'z-index', 'dropdown') + 1;
657
743
  }
658
744
  }
@@ -686,8 +772,6 @@ $mega-menu: null !default;
686
772
  background-color: map.get($mega-menu, 'global', 'greysh-background');
687
773
  box-shadow: none;
688
774
  display: none;
689
- font: map.get($mega-menu, 'mobile', 'subtitle-font');
690
- font-weight: map.get($mega-menu, 'mobile', 'subtitle-font-weight');
691
775
  }
692
776
  }
693
777
 
@@ -700,7 +784,7 @@ $mega-menu: null !default;
700
784
  display: none;
701
785
  }
702
786
 
703
- @include breakpoints.down('m') {
787
+ @include breakpoints.down('l') {
704
788
  .ecl-mega-menu--one-panel {
705
789
  .ecl-mega-menu__item--expanded > .ecl-mega-menu__link {
706
790
  font: var(--f-l);
@@ -727,6 +811,7 @@ $mega-menu: null !default;
727
811
  cursor: default;
728
812
  font: var(--f-l);
729
813
  margin: 0 calc(-1 * var(--s-xs));
814
+ width: 100vw;
730
815
 
731
816
  &::after {
732
817
  background: map.get(
@@ -738,9 +823,9 @@ $mega-menu: null !default;
738
823
  display: block;
739
824
  height: var(--s-xl);
740
825
  position: absolute;
741
- left: calc(-1 * var(--s-l));
826
+ left: 0;
742
827
  top: 100%;
743
- width: calc(100% + var(--s-l));
828
+ width: 100vw;
744
829
  }
745
830
  }
746
831
 
@@ -764,14 +849,17 @@ $mega-menu: null !default;
764
849
  list-style: none;
765
850
  list-style-image: url('data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7');
766
851
  margin-bottom: var(--s-m);
767
- padding-inline-start: 0;
852
+ padding: 0 var(--s-xs);
853
+
854
+ .ecl-mega-menu__sublist {
855
+ padding-inline: 0 !important;
856
+ }
768
857
 
769
858
  .ecl-mega-menu__see-all {
770
859
  .ecl-link {
771
860
  border-radius: 0;
772
861
  box-sizing: border-box;
773
- color: var(--c-d);
774
- font: var(--f-m);
862
+ color: var(--cm-on-surface-brand, var(--c-d));
775
863
  margin: 0 var(--s-l);
776
864
  padding: var(--s-xs) 0;
777
865
 
@@ -790,6 +878,25 @@ $mega-menu: null !default;
790
878
  }
791
879
  }
792
880
 
881
+ .ecl-mega-menu__see-all .ecl-link.ecl-mega-menu__info-link {
882
+ border-bottom: 1px solid transparent;
883
+ display: inline-block;
884
+ margin-block-end: var(--s-m);
885
+ width: fit-content;
886
+
887
+ &:hover {
888
+ text-decoration: underline !important;
889
+ }
890
+
891
+ &:focus-visible {
892
+ border-radius: 0;
893
+ }
894
+
895
+ .ecl-mega-menu__info-content + & {
896
+ margin-top: var(--s-xs);
897
+ }
898
+ }
899
+
793
900
  .ecl-mega-menu__featured-list {
794
901
  margin: 0;
795
902
  padding: 0;
@@ -798,10 +905,12 @@ $mega-menu: null !default;
798
905
  .ecl-mega-menu__sublink {
799
906
  background: transparent;
800
907
  box-sizing: border-box;
908
+ /* stylelint-disable-next-line declaration-property-value-no-unknown */
801
909
  border-bottom: 1.5px solid
802
910
  map.get($mega-menu, 'desktop', 'sublink-current-background');
803
911
  border-radius: 0;
804
912
  color: map.get($mega-menu, 'mobile', 'item-color');
913
+ font: map.get($mega-menu, 'global', 'font');
805
914
  padding: map.get($mega-menu, 'mobile', 'subitem-padding');
806
915
  position: relative;
807
916
  line-height: map.get($theme, 'line-height-ui', 'xs');
@@ -835,15 +944,15 @@ $mega-menu: null !default;
835
944
  }
836
945
 
837
946
  &--current {
838
- background-color: var(--c-n-80);
839
- box-shadow: inset 4px 0 0 0 var(--c-p);
947
+ background-color: var(--cm-surface-neutral-lowest, var(--c-n-80));
948
+ box-shadow: inset 4px 0 0 0 var(--cm-border-primary, var(--c-p));
840
949
  }
841
950
 
842
951
  &:focus-visible {
843
952
  background: transparent;
844
953
  border-color: transparent;
845
- color: var(--c-d);
846
- outline-color: var(--c-p);
954
+ color: var(--cm-on-surface-brand, var(--c-d));
955
+ outline-color: var(--cm-border-primary, var(--c-p));
847
956
  outline-offset: -2px;
848
957
  outline-width: 2px;
849
958
  }
@@ -855,30 +964,48 @@ $mega-menu: null !default;
855
964
  }
856
965
  }
857
966
 
858
- .ecl-mega-menu__sublist--scrollable {
967
+ .ecl-mega-menu__mega--has-featured {
968
+ @at-root .ecl-mega-menu--featured--primary
969
+ .ecl-mega-menu__subitem--current
970
+ .ecl-mega-menu__featured {
971
+ display: none !important;
972
+ }
973
+
974
+ @at-root .ecl-mega-menu--has-secondary-featured:not(
975
+ .ecl-mega-menu--featured--primary
976
+ )
977
+ &
978
+ > .ecl-mega-menu__featured {
979
+ display: none !important;
980
+ }
981
+
982
+ .ecl-mega-menu__featured-list__item:last-child {
983
+ padding-block-end: var(--s-m);
984
+ }
985
+
859
986
  @include with-scrollbar;
860
987
  }
861
988
 
862
- .ecl-mega-menu__mega--level-2 {
989
+ .ecl-mega-menu__sublist--scrollable {
863
990
  @include with-scrollbar;
991
+ }
864
992
 
865
- margin-top: var(--s-3xl);
866
- margin-inline-start: calc(-1 * var(--s-xs));
867
- margin-inline-end: calc(-1 * var(--s-xs));
993
+ .ecl-mega-menu__mega--level-2 {
994
+ margin-top: map.get($mega-menu, 'mobile', 'spacing-top-level-2');
868
995
 
869
996
  > .ecl-mega-menu__sublist {
870
997
  padding: 0 var(--s-xs);
871
998
  }
872
999
 
873
1000
  .ecl-mega-menu__sublink {
874
- color: var(--c-p);
1001
+ color: var(--cm-on-surface-primary, var(--c-p));
875
1002
 
876
1003
  &:hover {
877
1004
  text-decoration: underline;
878
1005
  }
879
1006
 
880
1007
  &:focus-visible {
881
- color: var(--c-p) !important;
1008
+ color: var(--cm-on-surface-primary, var(--c-p)) !important;
882
1009
  }
883
1010
 
884
1011
  &.ecl-mega-menu__sublink--last {
@@ -893,31 +1020,45 @@ $mega-menu: null !default;
893
1020
  .ecl-mega-menu__sublink .ecl-icon {
894
1021
  margin-inline-start: var(--s-xs);
895
1022
  }
1023
+
1024
+ &.ecl-mega-menu-featured-only {
1025
+ margin-block-start: var(--s-xl);
1026
+ }
896
1027
  }
897
1028
 
898
1029
  .ecl-mega-menu__featured {
899
1030
  background-color: map.get($mega-menu, 'mobile', 'featured-background');
900
- border-color: var(--c-n);
1031
+ border-color: var(--cm-border-neutral, var(--c-n));
901
1032
  border-width: 0.5px;
902
1033
  flex-direction: column;
903
- padding: 0 var(--s-xs);
1034
+ flex-grow: 1;
1035
+ padding: 0;
1036
+
1037
+ .ecl-mega-menu__featured-scrollable {
1038
+ background-color: map.get($mega-menu, 'mobile', 'featured-background');
1039
+ }
904
1040
 
905
1041
  .ecl-mega-menu__featured-picture {
906
1042
  display: block;
907
1043
 
908
1044
  .ecl-mega-menu__featured-image {
909
- aspect-ratio: 21/9;
1045
+ aspect-ratio: 3/2;
910
1046
  display: block;
911
1047
  margin-inline-start: var(--s-l);
1048
+ margin-block-start: var(--s-m);
912
1049
  max-width: 15.25rem;
913
1050
  }
914
1051
  }
915
1052
 
1053
+ .ecl-link .ecl-mega-menu__featured-picture .ecl-mega-menu__featured-image {
1054
+ margin-inline-start: var(--s-s);
1055
+ }
1056
+
916
1057
  .ecl-mega-menu__featured-title {
917
1058
  display: block;
918
1059
  margin: calc(var(--s-xs) + 2px) var(--s-m) calc(var(--s-xs) + 2px)
919
1060
  var(--s-l);
920
- font: var(--f-l);
1061
+ font: var(--f-m);
921
1062
  }
922
1063
 
923
1064
  .ecl-mega-menu__featured-content {
@@ -932,20 +1073,31 @@ $mega-menu: null !default;
932
1073
  .ecl-link {
933
1074
  border-radius: 0;
934
1075
  box-sizing: border-box;
935
- color: var(--c-p);
1076
+ color: var(--cm-on-surface-primary, var(--c-p));
936
1077
  display: block;
937
1078
  outline-offset: -2px;
938
- padding: var(--s-m) var(--s-l);
1079
+ padding: var(--s-2xs) var(--s-l);
939
1080
  width: 100%;
940
1081
 
941
1082
  &:hover {
942
- color: var(--c-p);
1083
+ color: var(--cm-on-surface-primary, var(--c-p));
943
1084
  }
944
1085
  }
1086
+
1087
+ &--image-only {
1088
+ margin-block-end: var(--s-2xs);
1089
+ }
945
1090
  }
946
1091
  }
947
1092
  }
948
1093
 
1094
+ .ecl-mega-menu__mega:not(.ecl-mega-menu__mega--level-2)
1095
+ > .ecl-mega-menu__featured {
1096
+ margin-inline: var(--s-xs);
1097
+ margin-block-start: calc(-1 * var(--s-m));
1098
+ padding-block: 0;
1099
+ }
1100
+
949
1101
  .ecl-mega-menu--rtl {
950
1102
  .ecl-mega-menu__see-all .ecl-icon,
951
1103
  .ecl-mega-menu__info-link .ecl-icon {
@@ -957,18 +1109,17 @@ $mega-menu: null !default;
957
1109
  }
958
1110
  }
959
1111
 
960
- @include breakpoints.up('l') {
1112
+ @include breakpoints.up('xl') {
961
1113
  .ecl-mega-menu:not(
962
- .ecl-mega-menu--forced-mobile,
963
- .ecl-mega-menu--forced-close
964
- ) {
1114
+ .ecl-mega-menu--forced-mobile,
1115
+ .ecl-mega-menu--forced-close
1116
+ ) {
965
1117
  .ecl-mega-menu__wrapper {
966
1118
  padding-top: var(--s-m);
967
1119
  min-height: 200px !important;
968
- width: 100vw;
969
1120
 
970
1121
  &::before {
971
- background: #e3e3e3;
1122
+ background: var(--cm-border-neutral, '#e3e3e3');
972
1123
  content: ' ';
973
1124
  display: block;
974
1125
  height: 1px;
@@ -998,7 +1149,7 @@ $mega-menu: null !default;
998
1149
  > .ecl-mega-menu__wrapper
999
1150
  > .ecl-container
1000
1151
  > .ecl-mega-menu__info {
1001
- background-color: map.get($theme, 'color', 'white');
1152
+ background-color: #fff;
1002
1153
  border: map.get($mega-menu, 'desktop', 'mega-border');
1003
1154
  border-radius: 0 0 map.get($mega-menu, 'global', 'border-radius')
1004
1155
  map.get($mega-menu, 'global', 'border-radius');
@@ -1015,15 +1166,21 @@ $mega-menu: null !default;
1015
1166
  z-index: map.get($theme, 'z-index', 'dropdown');
1016
1167
  }
1017
1168
 
1169
+ @at-root .ecl-mega-menu--rtl .ecl-mega-menu__info::after {
1170
+ right: auto !important;
1171
+ left: 10px !important;
1172
+ }
1173
+
1018
1174
  .ecl-mega-menu__item
1019
1175
  > .ecl-mega-menu__wrapper
1020
1176
  .ecl-container
1021
1177
  > .ecl-mega-menu__info {
1022
1178
  margin-bottom: var(--s-m);
1023
- margin-inline-start: calc(-1 * var(--s-m));
1024
- padding: 0 0 var(--s-m) var(--s-m);
1179
+ padding: 0 0 var(--s-m);
1025
1180
  position: static;
1026
1181
  width: auto;
1182
+
1183
+ @include with-scrollbar;
1027
1184
  }
1028
1185
 
1029
1186
  &.ecl-mega-menu--rtl {
@@ -1044,11 +1201,12 @@ $mega-menu: null !default;
1044
1201
  }
1045
1202
 
1046
1203
  .ecl-mega-menu__mega {
1204
+ overflow-x: visible;
1047
1205
  width: 21rem;
1048
1206
  }
1049
1207
 
1050
1208
  .ecl-mega-menu__item > .ecl-mega-menu__mega-container {
1051
- background-color: map.get($theme, 'color', 'white');
1209
+ background-color: #fff;
1052
1210
  top: 100%;
1053
1211
  width: 100%;
1054
1212
 
@@ -1097,11 +1255,39 @@ $mega-menu: null !default;
1097
1255
 
1098
1256
  > .ecl-mega-menu__info {
1099
1257
  box-sizing: border-box;
1100
- box-shadow: 0px 4px 10px 0px rgba(224, 229, 245, 0.42);
1258
+ box-shadow: 0px 4px 10px 0px rgb(224, 229, 245, 0.42);
1259
+ margin-inline: calc(
1260
+ -1 * map.get($mega-menu, 'desktop', 'container-padding-horizontal')
1261
+ );
1262
+ padding-inline-start: map.get(
1263
+ $mega-menu,
1264
+ 'desktop',
1265
+ 'container-padding-horizontal'
1266
+ );
1267
+ }
1268
+
1269
+ .ecl-mega-menu__mega:not(.ecl-mega-menu__mega--level-2)
1270
+ > .ecl-mega-menu__featured {
1271
+ background: var(--cm-on-surface-inverted, #fff);
1272
+ display: flex;
1273
+ height: auto;
1274
+ margin-block: 0;
1275
+ margin-inline-start: 21rem;
1276
+
1277
+ .ecl-mega-menu__featured-list__item .ecl-link {
1278
+ border-bottom: none;
1279
+ margin: 0;
1280
+ padding-inline: var(--s-s) 0;
1281
+ padding-block: var(--s-2xs);
1282
+ }
1283
+
1284
+ .ecl-mega-menu__featured-list__item .ecl-link > .ecl-picture {
1285
+ margin-block-start: calc(-1 * var(--s-2xs));
1286
+ }
1101
1287
  }
1102
1288
 
1103
1289
  .ecl-mega-menu__subitem--expanded .ecl-mega-menu__featured {
1104
- background: map.get($theme, 'color', 'white');
1290
+ background: #fff;
1105
1291
  display: flex;
1106
1292
  margin-bottom: 0;
1107
1293
 
@@ -1114,20 +1300,20 @@ $mega-menu: null !default;
1114
1300
  .ecl-mega-menu__featured-list__item .ecl-link {
1115
1301
  border-bottom: none;
1116
1302
  margin: 0;
1117
- padding: calc(var(--s-xs) + 2px) var(--s-2xl) calc(var(--s-xs) + 2px)
1118
- var(--s-s);
1303
+ padding-inline: var(--s-s) 0;
1304
+ padding-block: var(--s-2xs);
1119
1305
  }
1120
1306
  }
1121
1307
  }
1122
1308
 
1123
1309
  .ecl-mega-menu__sublist {
1124
- border-color: map.get($theme, 'color', 'white');
1310
+ border-color: #fff;
1125
1311
  border-width: 2px;
1126
1312
  display: flex;
1127
1313
  flex-direction: column;
1128
1314
  flex: 1;
1129
1315
  margin: 0;
1130
- padding-inline-start: 0;
1316
+ padding-inline: 0;
1131
1317
 
1132
1318
  @include with-scrollbar;
1133
1319
 
@@ -1139,6 +1325,7 @@ $mega-menu: null !default;
1139
1325
  display: block;
1140
1326
  flex-grow: 0;
1141
1327
  margin-top: auto;
1328
+ padding-inline-start: var(--s-xs);
1142
1329
  position: relative;
1143
1330
 
1144
1331
  .ecl-link {
@@ -1161,8 +1348,7 @@ $mega-menu: null !default;
1161
1348
  display: block;
1162
1349
  height: 1px;
1163
1350
  position: absolute;
1164
- left: var(--s-s);
1165
- top: calc(-1 * var(--s-s));
1351
+ left: var(--s-l);
1166
1352
  width: calc(100% - (var(--s-l) * 2));
1167
1353
  background: map.get($mega-menu, 'desktop', 'see-all-divider');
1168
1354
  }
@@ -1180,11 +1366,18 @@ $mega-menu: null !default;
1180
1366
  position: absolute;
1181
1367
  visibility: hidden;
1182
1368
  opacity: 0;
1183
- overflow-y: visible;
1184
1369
  transition-timing-function: ease;
1185
1370
  transition-property: opacity;
1186
1371
  transition-duration: 0.3s;
1187
1372
 
1373
+ @include with-scrollbar;
1374
+
1375
+ overflow-y: visible;
1376
+
1377
+ &.ecl-mega-menu-featured-only {
1378
+ background: var(--cm-surface-inverted, #fff);
1379
+ }
1380
+
1188
1381
  > .ecl-mega-menu__sublist {
1189
1382
  border: none;
1190
1383
  position: relative;
@@ -1210,7 +1403,7 @@ $mega-menu: null !default;
1210
1403
  }
1211
1404
 
1212
1405
  &:focus-visible {
1213
- outline-color: var(--c-p);
1406
+ outline-color: var(--cm-border-primary, var(--c-p));
1214
1407
  }
1215
1408
  }
1216
1409
  }
@@ -1252,14 +1445,14 @@ $mega-menu: null !default;
1252
1445
 
1253
1446
  &:focus-visible {
1254
1447
  border-color: transparent;
1255
- color: var(--c-d);
1256
- outline-color: var(--c-p);
1448
+ color: var(--cm-on-surface-brand, var(--c-d));
1449
+ outline-color: var(--cm-border-primary, var(--c-p));
1257
1450
  outline-width: 2px;
1258
1451
  }
1259
1452
  }
1260
1453
 
1261
1454
  .ecl-mega-menu__subitem[aria-expanded] > .ecl-mega-menu__sublink:hover {
1262
- background-color: var(--c-n-40);
1455
+ background-color: var(--cm-surface-neutral-lowest, var(--c-n-40));
1263
1456
  box-shadow: none;
1264
1457
  text-decoration: none;
1265
1458
  }
@@ -1273,7 +1466,7 @@ $mega-menu: null !default;
1273
1466
  'desktop',
1274
1467
  'sublink-current-background'
1275
1468
  );
1276
- border-color: var(--c-p);
1469
+ border-color: var(--cm-border-primary, var(--c-p));
1277
1470
  }
1278
1471
  }
1279
1472
  }
@@ -1284,13 +1477,16 @@ $mega-menu: null !default;
1284
1477
  font: var(--f-m);
1285
1478
  height: 100%;
1286
1479
  margin: 0;
1287
- padding-inline-start: 0;
1480
+ padding-inline: 0;
1288
1481
  position: absolute;
1289
1482
  left: calc(100% + var(--s-m));
1290
1483
  width: 16.25rem;
1291
1484
  top: 0;
1292
1485
 
1293
1486
  .ecl-mega-menu__featured-scrollable {
1487
+ background-color: transparent;
1488
+ height: 100%;
1489
+
1294
1490
  @include with-scrollbar;
1295
1491
  }
1296
1492
 
@@ -1298,8 +1494,9 @@ $mega-menu: null !default;
1298
1494
  display: block;
1299
1495
 
1300
1496
  .ecl-mega-menu__featured-image {
1301
- aspect-ratio: 21/9;
1497
+ aspect-ratio: 3/2;
1302
1498
  display: block;
1499
+ margin-block-start: 0;
1303
1500
  margin-inline-start: var(--s-s);
1304
1501
  max-width: calc(100% - var(--s-s));
1305
1502
  }
@@ -1310,29 +1507,51 @@ $mega-menu: null !default;
1310
1507
  }
1311
1508
 
1312
1509
  .ecl-mega-menu__featured-title {
1313
- font: var(--f-m);
1510
+ font: var(--f-l);
1314
1511
  margin-bottom: calc(var(--s-xs) + 2px);
1315
1512
  margin-top: calc(var(--s-xs) + 2px);
1316
1513
  margin-inline-start: var(--s-s);
1317
1514
  }
1318
1515
  }
1516
+
1517
+ .ecl-mega-menu__mega--has-featured {
1518
+ overflow-y: unset;
1519
+ }
1319
1520
  }
1320
1521
 
1321
- @include breakpoints.up('xl') {
1522
+ @media (width >= 1368px) {
1322
1523
  .ecl-mega-menu:not(
1323
- .ecl-mega-menu--forced-mobile,
1324
- .ecl-mega-menu--forced-close
1325
- ) {
1524
+ .ecl-mega-menu--forced-mobile,
1525
+ .ecl-mega-menu--forced-close
1526
+ ) {
1527
+ .ecl-container {
1528
+ padding-inline: map.get(
1529
+ $mega-menu,
1530
+ 'desktop',
1531
+ 'container-extra-large-padding-horizontal'
1532
+ );
1533
+ }
1534
+
1535
+ .ecl-mega-menu__inner {
1536
+ margin-inline-start: calc(-1 * var(--s-m));
1537
+ }
1538
+
1326
1539
  .ecl-mega-menu__item.ecl-mega-menu__item--expanded
1327
1540
  > .ecl-mega-menu__wrapper
1328
1541
  > .ecl-container {
1329
1542
  > .ecl-mega-menu__info {
1330
1543
  box-shadow: none;
1331
- border-radius: 0px 4px 4px 0px;
1332
- left: var(--s-m);
1544
+ border-radius: 0px map.get($theme, 'border-radius', 's')
1545
+ map.get($theme, 'border-radius', 's') 0px;
1546
+ left: map.get(
1547
+ $mega-menu,
1548
+ 'desktop',
1549
+ 'container-extra-large-padding-horizontal'
1550
+ );
1333
1551
  margin-bottom: 0;
1334
- padding-inline-start: var(--s-m);
1335
- padding-inline-end: var(--s-xl);
1552
+ margin-inline: 0;
1553
+ padding-inline-start: 0;
1554
+ padding-inline-end: 1.5rem;
1336
1555
  position: absolute;
1337
1556
  width: 15.875rem;
1338
1557
  z-index: 16;
@@ -1341,10 +1560,10 @@ $mega-menu: null !default;
1341
1560
  content: '';
1342
1561
  position: absolute;
1343
1562
  top: 0;
1344
- right: 0;
1563
+ right: 10px;
1345
1564
  bottom: 0;
1346
1565
  width: 10px;
1347
- box-shadow: 4px 0px 10px 0px rgba(224, 229, 245, 0.5);
1566
+ box-shadow: 4px 0px 10px 0px rgb(224, 229, 245, 0.5);
1348
1567
  pointer-events: none;
1349
1568
  }
1350
1569
 
@@ -1369,10 +1588,19 @@ $mega-menu: null !default;
1369
1588
  }
1370
1589
 
1371
1590
  > .ecl-mega-menu__mega {
1372
- left: calc(15.875rem + var(--s-xl));
1591
+ left: 18rem;
1373
1592
  }
1374
1593
  }
1375
1594
 
1595
+ &.ecl-mega-menu--rtl .ecl-mega-menu__info {
1596
+ left: auto !important;
1597
+ right: map.get(
1598
+ $mega-menu,
1599
+ 'desktop',
1600
+ 'container-extra-large-padding-horizontal'
1601
+ ) !important;
1602
+ }
1603
+
1376
1604
  &.ecl-mega-menu--rtl
1377
1605
  .ecl-mega-menu__item--expanded
1378
1606
  > .ecl-mega-menu__wrapper
@@ -1385,9 +1613,22 @@ $mega-menu: null !default;
1385
1613
 
1386
1614
  @include breakpoints.up('xl') {
1387
1615
  .ecl-mega-menu:not(
1388
- .ecl-mega-menu--forced-mobile,
1389
- .ecl-mega-menu--forced-close
1390
- ) {
1616
+ .ecl-mega-menu--forced-mobile,
1617
+ .ecl-mega-menu--forced-close
1618
+ ) {
1619
+ .ecl-container {
1620
+ padding-inline: map.get(
1621
+ $mega-menu,
1622
+ 'global',
1623
+ 'container-extra-large-padding-horizontal'
1624
+ );
1625
+ }
1626
+
1627
+ .ecl-mega-menu__mega:not(.ecl-mega-menu__mega--level-2)
1628
+ > .ecl-mega-menu__featured {
1629
+ margin-inline-start: 18.75rem !important;
1630
+ }
1631
+
1391
1632
  .ecl-mega-menu__wrapper::before {
1392
1633
  width: 96%;
1393
1634
  margin-inline-start: 2%;
@@ -1395,6 +1636,50 @@ $mega-menu: null !default;
1395
1636
  }
1396
1637
  }
1397
1638
 
1639
+ @media (width >= 1368px) {
1640
+ .ecl-mega-menu:not(
1641
+ .ecl-mega-menu--forced-mobile,
1642
+ .ecl-mega-menu--forced-close
1643
+ ) {
1644
+ .ecl-mega-menu__mega:not(.ecl-mega-menu__mega--level-2)
1645
+ > .ecl-mega-menu__featured {
1646
+ margin-inline-start: 20.68rem !important;
1647
+ }
1648
+
1649
+ .ecl-mega-menu__item.ecl-mega-menu__item--expanded
1650
+ > .ecl-mega-menu__wrapper
1651
+ > .ecl-container {
1652
+ .ecl-mega-menu__featured {
1653
+ width: 17.875rem;
1654
+ }
1655
+
1656
+ .ecl-mega-menu__mega {
1657
+ width: 20.68rem;
1658
+ }
1659
+
1660
+ > {
1661
+ .ecl-mega-menu__info {
1662
+ padding-inline-start: 0;
1663
+ width: 18.875rem;
1664
+ }
1665
+
1666
+ .ecl-mega-menu__mega {
1667
+ left: 22rem;
1668
+ width: 20.93rem;
1669
+ }
1670
+ }
1671
+ }
1672
+
1673
+ &.ecl-mega-menu--rtl
1674
+ .ecl-mega-menu__item--expanded
1675
+ > .ecl-mega-menu__wrapper
1676
+ > .ecl-container
1677
+ > .ecl-mega-menu__mega {
1678
+ right: 20.93rem;
1679
+ }
1680
+ }
1681
+ }
1682
+
1398
1683
  .ecl-mega-menu-prevent-scroll {
1399
1684
  position: fixed;
1400
1685
  overflow-y: scroll;