@undrr/undrr-mangrove 1.3.2 → 1.4.0

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.
Files changed (156) hide show
  1. package/README.md +32 -25
  2. package/components/BarChart.js +2 -2
  3. package/components/BookCard.js +6 -0
  4. package/components/BookCard.js.LICENSE.txt +11 -0
  5. package/components/Breadcrumbs.js +6 -0
  6. package/components/Breadcrumbs.js.LICENSE.txt +9 -0
  7. package/components/Checkbox.js +6 -0
  8. package/components/Checkbox.js.LICENSE.txt +9 -0
  9. package/components/Chips.js +6 -0
  10. package/components/Chips.js.LICENSE.txt +9 -0
  11. package/components/CtaButton.js +6 -0
  12. package/components/CtaButton.js.LICENSE.txt +9 -0
  13. package/components/EmbedContainer.js +6 -0
  14. package/components/EmbedContainer.js.LICENSE.txt +9 -0
  15. package/components/Fetcher.js +2 -2
  16. package/components/Footer.js +6 -0
  17. package/components/Footer.js.LICENSE.txt +9 -0
  18. package/components/FormErrorSummary.js +6 -0
  19. package/components/FormErrorSummary.js.LICENSE.txt +9 -0
  20. package/components/FormGroup.js +6 -0
  21. package/components/FormGroup.js.LICENSE.txt +9 -0
  22. package/components/FullWidth.js +6 -0
  23. package/components/FullWidth.js.LICENSE.txt +9 -0
  24. package/components/Gallery.js +2 -2
  25. package/components/Hero.js +6 -0
  26. package/components/Hero.js.LICENSE.txt +9 -0
  27. package/components/HighlightBox.js +6 -0
  28. package/components/HighlightBox.js.LICENSE.txt +9 -0
  29. package/components/HorizontalBookCard.js +6 -0
  30. package/components/HorizontalBookCard.js.LICENSE.txt +11 -0
  31. package/components/HorizontalCard.js +6 -0
  32. package/components/HorizontalCard.js.LICENSE.txt +11 -0
  33. package/components/IconCard.js +2 -2
  34. package/components/IconCard.js.LICENSE.txt +1 -1
  35. package/components/Loader.js +6 -0
  36. package/components/Loader.js.LICENSE.txt +9 -0
  37. package/components/MapComponent.js +2 -2
  38. package/components/MegaMenu.js +2 -2
  39. package/components/PageHeader.js +6 -0
  40. package/components/PageHeader.js.LICENSE.txt +9 -0
  41. package/components/Pager.js +2 -2
  42. package/components/QuoteHighlight.js +2 -2
  43. package/components/Radio.js +6 -0
  44. package/components/Radio.js.LICENSE.txt +9 -0
  45. package/components/ScrollContainer.js +2 -2
  46. package/components/Select.js +6 -0
  47. package/components/Select.js.LICENSE.txt +9 -0
  48. package/components/ShareButtons.js +2 -2
  49. package/components/ShowMore.js +6 -0
  50. package/components/ShowMore.js.LICENSE.txt +9 -0
  51. package/components/StatsCard.js +2 -2
  52. package/components/SyndicationSearchWidget.js +2 -2
  53. package/components/Tab.js +6 -0
  54. package/components/Tab.js.LICENSE.txt +9 -0
  55. package/components/TextCta.js +6 -0
  56. package/components/TextCta.js.LICENSE.txt +11 -0
  57. package/components/TextInput.js +6 -0
  58. package/components/TextInput.js.LICENSE.txt +9 -0
  59. package/components/Textarea.js +6 -0
  60. package/components/Textarea.js.LICENSE.txt +9 -0
  61. package/components/VerticalCard.js +6 -0
  62. package/components/VerticalCard.js.LICENSE.txt +11 -0
  63. package/components/hydrate.js +5 -0
  64. package/css/style-delta.css +464 -0
  65. package/css/style-delta.css.map +1 -0
  66. package/css/style-gutenberg.css +19 -18
  67. package/css/style-gutenberg.css.map +1 -1
  68. package/css/style-irp-legacy.css +469 -0
  69. package/css/style-irp-legacy.css.map +1 -0
  70. package/css/style-irp.css +96 -103
  71. package/css/style-irp.css.map +1 -1
  72. package/css/style-legacy.css +462 -0
  73. package/css/style-legacy.css.map +1 -0
  74. package/css/style-mcr-legacy.css +469 -0
  75. package/css/style-mcr-legacy.css.map +1 -0
  76. package/css/style-mcr.css +96 -103
  77. package/css/style-mcr.css.map +1 -1
  78. package/css/style-preventionweb-legacy.css +469 -0
  79. package/css/style-preventionweb-legacy.css.map +1 -0
  80. package/css/style-preventionweb.css +96 -103
  81. package/css/style-preventionweb.css.map +1 -1
  82. package/css/style.css +96 -103
  83. package/css/style.css.map +1 -1
  84. package/error-pages/401.html +10 -11
  85. package/error-pages/403.html +11 -12
  86. package/error-pages/404.html +13 -14
  87. package/error-pages/429.html +12 -13
  88. package/error-pages/500.html +10 -11
  89. package/error-pages/502.html +12 -13
  90. package/error-pages/503.html +12 -13
  91. package/error-pages/504.html +10 -11
  92. package/error-pages/5xx.html +10 -11
  93. package/error-pages/challenge.html +12 -13
  94. package/error-pages/managed-challenge.html +12 -13
  95. package/js/tabs.js +427 -88
  96. package/package.json +1 -1
  97. package/scss/Atom/BaseTypography/Blockquote/blockquote.scss +1 -8
  98. package/scss/Atom/BaseTypography/Cite/cite.scss +2 -2
  99. package/scss/Atom/Images/AuthorImage/author-image.scss +4 -4
  100. package/scss/Atom/Images/ImageCaptionCredit/image-caption-credit.scss +24 -28
  101. package/scss/Atom/Images/ImageCredit/image-credit.scss +1 -1
  102. package/scss/Atom/Layout/Container/container.scss +2 -2
  103. package/scss/Atom/Layout/Grid/grid.scss +1 -1
  104. package/scss/Atom/ReachElement/Details/details.scss +6 -6
  105. package/scss/Atom/ReachElement/Figcaption/figcaption.scss +1 -1
  106. package/scss/Atom/Table/table.scss +0 -8
  107. package/scss/Components/Boilerplate/boilerplate.scss +2 -2
  108. package/scss/Components/Breadcrumbs/breadcrumbs.scss +2 -9
  109. package/scss/Components/Buttons/Chips/chips.scss +5 -19
  110. package/scss/Components/Buttons/CtaButton/buttons.scss +3 -124
  111. package/scss/Components/Buttons/CtaButton/cta-button.scss +124 -0
  112. package/scss/Components/Buttons/ShareButtons/share-buttons.scss +2 -2
  113. package/scss/Components/Cards/Card/card.scss +41 -2
  114. package/scss/Components/ErrorPages/error-pages.scss +12 -12
  115. package/scss/Components/Footer/footer.scss +72 -4
  116. package/scss/Components/Forms/Select/select.scss +2 -2
  117. package/scss/Components/Forms/_form-base.scss +5 -5
  118. package/scss/Components/Forms/_form-legacy.scss +1 -1
  119. package/scss/Components/Gallery/gallery.scss +4 -4
  120. package/scss/Components/Hero/hero.scss +18 -17
  121. package/scss/Components/HighlightBox/highlight-box.scss +5 -5
  122. package/scss/Components/MegaMenu/mega-menu.scss +750 -0
  123. package/scss/Components/MegaMenu/megamenu.scss +3 -659
  124. package/scss/Components/PageHeader/page-header.scss +4 -4
  125. package/scss/Components/Pagination/pagination.scss +2 -2
  126. package/scss/Components/SyndicationSearchWidget/SyndicationSearchWidget.scss +3 -1480
  127. package/scss/Components/SyndicationSearchWidget/syndication-search-widget.scss +1515 -0
  128. package/scss/Components/Tab/tab.scss +66 -7
  129. package/scss/Components/TextCta/text-cta.scss +129 -0
  130. package/scss/Components/TextCta/textcta.scss +3 -27
  131. package/scss/Molecules/ImageCaption/image-caption.scss +6 -16
  132. package/scss/Molecules/SectionHeader/section-header.scss +8 -0
  133. package/scss/Molecules/SectionHeader/sectionheader.scss +3 -8
  134. package/scss/Utilities/FullWidth/FullWidth.scss +3 -23
  135. package/scss/Utilities/FullWidth/full-width.scss +23 -0
  136. package/scss/Utilities/Loader/loader.scss +1 -1
  137. package/scss/Utilities/ShowMore/ShowMore.scss +3 -26
  138. package/scss/Utilities/ShowMore/show-more.scss +26 -0
  139. package/scss/assets/scss/_components.scss +14 -9
  140. package/scss/assets/scss/_foundational.scss +13 -7
  141. package/scss/assets/scss/_mixins.scss +9 -314
  142. package/scss/assets/scss/_utility.scss +19 -71
  143. package/scss/assets/scss/_variables-delta.scss +105 -0
  144. package/scss/assets/scss/_variables-irp.scss +1 -1
  145. package/scss/assets/scss/_variables-mcr.scss +1 -1
  146. package/scss/assets/scss/_variables-preventionweb.scss +1 -1
  147. package/scss/assets/scss/_variables.scss +68 -34
  148. package/scss/assets/scss/style-delta.scss +8 -0
  149. package/scss/assets/scss/style-gutenberg.scss +2 -2
  150. package/scss/assets/scss/style-irp-legacy.scss +20 -0
  151. package/scss/assets/scss/style-legacy.scss +20 -0
  152. package/scss/assets/scss/style-mcr-legacy.scss +20 -0
  153. package/scss/assets/scss/style-preventionweb-legacy.scss +20 -0
  154. package/scss/Components/BlockquoteComponent/blockquotecomp.scss +0 -31
  155. package/scss/Components/Buttons/CtaLink/cta-link.scss +0 -61
  156. /package/scss/Components/TableOfContents/{TableOfContents.scss → table-of-contents.scss} +0 -0
@@ -0,0 +1,750 @@
1
+ .mg-mega-wrapper {
2
+ position: relative;
3
+ background: $mg-color-white;
4
+ box-shadow: 0 2px 3px 0 rgb(51 51 51 / 0.31);
5
+ z-index: 10;
6
+ }
7
+
8
+ .mg-mega-topbar {
9
+ width: 100%;
10
+ display: flex;
11
+ align-items: flex-start;
12
+ z-index: 10;
13
+ padding: 0;
14
+ max-width: $mg-breakpoint-desktop;
15
+ margin: 0 auto;
16
+
17
+ @media screen and (min-width: $mg-breakpoint-desktop-wide) {
18
+ max-width: $mg-breakpoint-desktop-wide;
19
+ }
20
+
21
+ // these are note "mobile first" as they seem to cause a glitch with firefox and .mg-container-full-width
22
+ @media screen and (max-width: $mg-breakpoint-tablet) {
23
+ padding-left: mg-rem(40); // space for the icon button
24
+ overflow-x: hidden; // primarily for mobile
25
+ }
26
+
27
+ // --- Branded variant (with inline logo) ---
28
+ &--branded {
29
+ align-items: center;
30
+
31
+ @media screen and (max-width: $mg-breakpoint-tablet) {
32
+ padding-left: 0; // logo replaces the left padding
33
+ overflow-x: hidden;
34
+ }
35
+
36
+ // Hamburger becomes a discrete button (not full-width overlay)
37
+ .mg-mega-topbar-mobile__icon-button {
38
+ position: relative;
39
+ width: auto;
40
+ margin-inline-start: auto;
41
+ background: $mg-color-white;
42
+ flex-shrink: 0;
43
+ box-shadow: -3px 0 6px -2px rgb(0 0 0 / 0.15);
44
+
45
+ &:has(.mg-icon-angle-circled-left) {
46
+ background: $mg-color-white;
47
+ box-shadow: -3px 0 6px -2px rgb(0 0 0 / 0.15);
48
+ }
49
+ }
50
+ }
51
+
52
+ // Nav list inside branded variant — push items to the end
53
+ &--branded &__nav {
54
+ display: flex;
55
+ justify-content: flex-end;
56
+ flex: 1;
57
+ list-style: none;
58
+ margin: 0;
59
+ padding: 0;
60
+ }
61
+
62
+ // Logo link
63
+ &__logo {
64
+ flex-shrink: 1;
65
+ min-width: 0; // allow shrinking below intrinsic size
66
+ display: flex;
67
+ align-items: center;
68
+ padding: $mg-spacing-100 $mg-spacing-150;
69
+ }
70
+
71
+ // Logo image
72
+ &__logo-img {
73
+ display: block;
74
+ height: mg-rem(30);
75
+ max-width: 100%;
76
+ width: auto;
77
+
78
+ @media screen and (min-width: $mg-breakpoint-tablet) {
79
+ height: mg-rem(35);
80
+ }
81
+ }
82
+
83
+ // Inner nav list inside branded variant
84
+ &__nav {
85
+ display: flex;
86
+ align-items: flex-start;
87
+ flex: 1;
88
+ padding: 0;
89
+ margin: 0;
90
+ list-style: none;
91
+
92
+ // Hide items on mobile (same as default topbar behavior)
93
+ @media screen and (max-width: $mg-breakpoint-tablet) {
94
+ // Items are there but non-interactive on mobile (hamburger opens sidebar)
95
+ pointer-events: none;
96
+ overflow: hidden;
97
+ flex: 1;
98
+ min-width: 0;
99
+ }
100
+ }
101
+
102
+ // Hide desktop menu items on mobile/tablet, show on desktop
103
+ &__item {
104
+ pointer-events: none; // on mobile we only advertise the buttons, but not clickable
105
+
106
+ @media screen and (min-width: $mg-breakpoint-tablet) {
107
+ display: block;
108
+ pointer-events: unset;
109
+ }
110
+
111
+ .mg-mega-content {
112
+ display: none;
113
+ }
114
+
115
+ font-size: $mg-font-size-300;
116
+ color: $mg-color-interactive;
117
+ font-weight: bold;
118
+ list-style: none;
119
+ padding: 0;
120
+ margin: 0;
121
+
122
+ p {
123
+ font-weight: normal;
124
+ }
125
+
126
+ > a,
127
+ > button {
128
+ padding: $mg-spacing-150;
129
+ display: block;
130
+ cursor: pointer;
131
+ line-height: mg-rem(18); // normalization
132
+ width: max-content; // overflow menu style on mobile
133
+
134
+ @media screen and (min-width: $mg-breakpoint-tablet) {
135
+ width: unset;
136
+ }
137
+ }
138
+
139
+ @media screen and (min-width: $mg-breakpoint-tablet) {
140
+ &--active {
141
+ background: rgba($mg-color-interactive, 0.2);
142
+
143
+ a,
144
+ .mg-mega-topbar__item-link {
145
+ color: $mg-color-interactive;
146
+ text-decoration: none;
147
+ }
148
+
149
+ a.mg-button-primary {
150
+ color: $mg-color-white;
151
+ text-decoration: none;
152
+ }
153
+
154
+ .mg-mega-content {
155
+ display: flex;
156
+ }
157
+ }
158
+ }
159
+ }
160
+
161
+ &__item-link {
162
+ font-family: $mg-font-family-condensed;
163
+ color: $mg-color-interactive;
164
+ background: none;
165
+ border: none;
166
+ font-weight: bold;
167
+ cursor: pointer;
168
+ list-style: none;
169
+ }
170
+
171
+ // Optional icon before the top-level menu label
172
+ &__item-icon {
173
+ margin-inline-end: 0.35em;
174
+ font-size: 0.85em;
175
+ vertical-align: baseline;
176
+ }
177
+
178
+ // Desktop: Make the top level button links larger
179
+ @media screen and (min-width: $mg-breakpoint-tablet) {
180
+ &__item-link {
181
+ font-size: $mg-font-size-400;
182
+ }
183
+ }
184
+ }
185
+
186
+ .mg-mega-content {
187
+ // Mobile-first: Start with mobile styles
188
+ display: flex;
189
+ flex-direction: column;
190
+ height: auto;
191
+ position: relative;
192
+ top: 1px;
193
+ align-items: flex-start;
194
+ justify-content: start;
195
+ background-color: rgba($mg-color-mega-content-bg, 0.7);
196
+ backdrop-filter: blur(10px);
197
+ border-radius: $mg-radius-tab;
198
+ box-shadow: -1px 5px 10px -1px rgb(0 0 0 / 0.25);
199
+ inset-inline-start: 0;
200
+ z-index: 1;
201
+ width: 100%;
202
+
203
+ // Desktop: Float over content with horizontal layout
204
+ @media screen and (min-width: $mg-breakpoint-tablet) {
205
+ display: none;
206
+ flex-direction: row; // Horizontal layout for left/right sections
207
+ height: mg-rem(350);
208
+ overflow: hidden;
209
+ top: mg-rem(48);
210
+ position: absolute;
211
+ }
212
+
213
+ &.mg-container-full-width {
214
+ position: absolute;
215
+ }
216
+
217
+ &__left {
218
+ height: 100%;
219
+ width: 100%; // mobile-first
220
+ background-color: rgba($mg-color-mega-content-bg, 0.8);
221
+
222
+ @media screen and (min-width: $mg-breakpoint-tablet) {
223
+ flex-basis: 33%;
224
+ }
225
+ }
226
+ &__banner {
227
+ padding: $mg-spacing-250;
228
+ header {
229
+ font-size: $mg-font-size-500;
230
+ font-weight: bold;
231
+ padding-bottom: $mg-spacing-100;
232
+ }
233
+ p {
234
+ a {
235
+ text-decoration: underline;
236
+ }
237
+ a:hover {
238
+ text-decoration: none;
239
+ }
240
+ }
241
+ }
242
+ }
243
+
244
+ .mg-mega-content,
245
+ .mg-mega-content__left,
246
+ .mg-mega-content__right,
247
+ .mg-mega-topbar__item-link {
248
+ &:focus-visible {
249
+ outline: -webkit-focus-ring-color auto 1px;
250
+ outline-offset: 1px;
251
+ }
252
+ }
253
+
254
+ .mg-mega-content__left {
255
+ box-shadow: inset 0 5px 5px -3px rgb(0 0 0 / 0.2);
256
+
257
+ // RTL-friendly border
258
+ border-inline-end: 2px solid rgba($mg-color-black, 0.2);
259
+
260
+ // Mobile-first: Hide section list on mobile
261
+ .mg-mega-content__section-list {
262
+ display: none;
263
+
264
+ @media screen and (min-width: $mg-breakpoint-tablet) {
265
+ display: block;
266
+ }
267
+ }
268
+
269
+ .mg-mega-content__section-list-link:hover,
270
+ .mg-mega-content__section-list-link {
271
+ color: $mg-color-interactive-active;
272
+ }
273
+ }
274
+
275
+ .mg-mega-content__section-list {
276
+ padding-inline: $mg-spacing-200;
277
+ }
278
+
279
+ .mg-mega-content__section-list-item {
280
+ list-style: none;
281
+ padding: 0;
282
+ margin: 0;
283
+
284
+ .mg-mega-content__section-list-link {
285
+ text-decoration: none;
286
+ display: block;
287
+
288
+ // RTL-friendly: Use logical properties for better improvements
289
+ letter-spacing: 0.2px;
290
+ position: relative;
291
+ padding: $mg-spacing-150 $mg-spacing-250;
292
+ margin-inline: -$mg-spacing-200; // extend hit area to both edges
293
+ font-weight: 600;
294
+ transition:
295
+ background-color 150ms ease,
296
+ color 150ms ease,
297
+ transform 150ms ease;
298
+
299
+ &:hover,
300
+ &:focus-visible {
301
+ background: rgba($mg-color-interactive, 0.15);
302
+ text-decoration: underline;
303
+ }
304
+
305
+ // RTL-friendly chevron indicator
306
+ &::after {
307
+ content: "›";
308
+ display: inline-block;
309
+ position: absolute;
310
+ font-size: mg-rem(30);
311
+ inset-inline-end: auto;
312
+ padding-inline-start: $mg-spacing-150;
313
+ margin-inline-end: $mg-spacing-150;
314
+ transition:
315
+ transform 150ms ease,
316
+ inset-inline-start 200ms cubic-bezier(0.4, 0, 0.2, 1),
317
+ inset-inline-end 200ms cubic-bezier(0.4, 0, 0.2, 1),
318
+ opacity 150ms ease;
319
+ opacity: 0.55;
320
+ }
321
+
322
+ &--active {
323
+ padding: $mg-spacing-150 $mg-spacing-250;
324
+ margin-inline-start: -$mg-spacing-200;
325
+ border-inline-start: 4px solid $mg-color-interactive; // RTL-friendly vertical rule
326
+ text-decoration: underline;
327
+ background: rgba($mg-color-interactive, 0.15);
328
+
329
+ &::after {
330
+ opacity: 1;
331
+ inset-inline-end: 0;
332
+ }
333
+ }
334
+ }
335
+ }
336
+
337
+ // RTL: Flip chevron direction
338
+ [dir="rtl"]
339
+ .mg-mega-content__section-list-item
340
+ .mg-mega-content__section-list-link::after {
341
+ content: "‹";
342
+ }
343
+
344
+ /* Brief pulse to draw attention when active becomes visible */
345
+ @keyframes mg-mega-tab-pulse {
346
+ 0% {
347
+ box-shadow:
348
+ inset 4px 0 0 0 $mg-color-button,
349
+ 0 0 0 0 rgba($mg-color-interactive, 0);
350
+ }
351
+ 60% {
352
+ box-shadow:
353
+ inset 4px 0 0 0 $mg-color-button,
354
+ 0 0 0 8px rgba($mg-color-interactive, 0.12);
355
+ }
356
+ 100% {
357
+ box-shadow:
358
+ inset 4px 0 0 0 $mg-color-button,
359
+ 0 0 0 0 rgba($mg-color-interactive, 0);
360
+ }
361
+ }
362
+
363
+ .mg-mega-content__section-list-link--active {
364
+ animation: mg-mega-tab-pulse 700ms ease-out 1;
365
+ }
366
+
367
+ /* Slide motion for right content when tab changes */
368
+ @keyframes mg-mega-content-swap {
369
+ 0% {
370
+ transform: translateX(8px);
371
+ opacity: 0.98;
372
+ }
373
+ 100% {
374
+ transform: translateX(0);
375
+ opacity: 1;
376
+ }
377
+ }
378
+
379
+ .mg-mega-content__right--sliding {
380
+ animation: mg-mega-content-swap 180ms ease-out;
381
+ }
382
+
383
+ /* Stronger keyboard focus ring for accessibility */
384
+ .mg-mega-content__section-list-link:focus-visible {
385
+ outline: 2px solid $mg-color-white;
386
+ outline-offset: -2px;
387
+ }
388
+
389
+ .mg-mega-content__right {
390
+ box-shadow: inset 0 5px 5px -3px rgb(0 0 0 / 0.2);
391
+ flex: 1;
392
+ height: 100%;
393
+ display: flex;
394
+
395
+ // Mobile-first: full width by default
396
+ width: 100%;
397
+
398
+ // Mobile-first: Show mobile menu, hide desktop menu
399
+ .mg-mega-content__menu--mobile {
400
+ display: block;
401
+ }
402
+
403
+ .mg-mega-content__menu--desktop {
404
+ display: none;
405
+ }
406
+
407
+ // Desktop: Hide mobile menu, show desktop menu
408
+ @media screen and (min-width: $mg-breakpoint-tablet) {
409
+ .mg-mega-content__menu--mobile {
410
+ display: none;
411
+ }
412
+
413
+ .mg-mega-content__menu--desktop {
414
+ display: block;
415
+
416
+ // Blue flash background that fades out (retriggered via React key)
417
+ animation: mg-mega-right-flash 400ms ease-out;
418
+
419
+ // Staggered slide-in for menu items
420
+ li {
421
+ animation: mg-mega-item-slide-in 250ms ease-out both;
422
+
423
+ @for $i from 1 through 25 {
424
+ &:nth-child(#{$i}) {
425
+ animation-delay: #{($i - 1) * 30}ms;
426
+ }
427
+ }
428
+ }
429
+ }
430
+ }
431
+
432
+ ul {
433
+ flex: 1;
434
+ padding: $mg-spacing-150;
435
+ list-style: none;
436
+ column-count: auto;
437
+ column-width: 300px;
438
+ column-gap: $mg-spacing-200;
439
+ column-fill: balance;
440
+
441
+ // nested menus - RTL-friendly
442
+ ul {
443
+ padding-block: 0;
444
+ padding-inline: $mg-spacing-150;
445
+ opacity: 0.8;
446
+ break-inside: avoid;
447
+ }
448
+
449
+ li {
450
+ padding: 0;
451
+ margin: 0;
452
+ break-inside: avoid;
453
+
454
+ a {
455
+ display: block;
456
+ padding: $mg-spacing-50;
457
+ overflow: hidden;
458
+ white-space: wrap;
459
+ text-overflow: clip;
460
+ color: $mg-color-black;
461
+ font-weight: bold;
462
+
463
+ &:hover {
464
+ color: $mg-color-black;
465
+ text-decoration: underline;
466
+ }
467
+ }
468
+ }
469
+ }
470
+ }
471
+
472
+ /* Subtle blue gradient flash that fades to transparent on right content area */
473
+ @keyframes mg-mega-right-flash {
474
+ 0% {
475
+ background: linear-gradient(
476
+ to bottom,
477
+ rgba($mg-color-interactive, 0.06) 0%,
478
+ transparent 100%
479
+ );
480
+ }
481
+ 100% {
482
+ background: transparent;
483
+ }
484
+ }
485
+
486
+ /* Menu items slide in from the left */
487
+ @keyframes mg-mega-item-slide-in {
488
+ 0% {
489
+ opacity: 0;
490
+ transform: translateX(-12px);
491
+ }
492
+ 100% {
493
+ opacity: 1;
494
+ transform: translateX(0);
495
+ }
496
+ }
497
+
498
+ .mg-icon-button {
499
+ padding: $mg-spacing-100;
500
+ background-color: transparent;
501
+ border: none;
502
+ cursor: pointer;
503
+ display: flex;
504
+ align-items: center;
505
+ justify-content: center;
506
+
507
+ &:hover {
508
+ background-color: $mg-color-interactive-active;
509
+ }
510
+ }
511
+
512
+ .mg-mega-sidebar-section {
513
+ list-style: none;
514
+
515
+ ol {
516
+ list-style: none;
517
+ margin: 0;
518
+
519
+ li {
520
+ margin: 0;
521
+ }
522
+
523
+ ol li {
524
+ list-style: none;
525
+ padding-block: $mg-spacing-50;
526
+ padding-inline-start: $mg-spacing-300; // RTL-friendly
527
+ margin: 0;
528
+
529
+ a {
530
+ color: $mg-color-white;
531
+ text-decoration: none;
532
+ }
533
+
534
+ &:hover {
535
+ background: $mg-color-interactive-active;
536
+ }
537
+ }
538
+ }
539
+ }
540
+
541
+ .mg-mega-sidebar-section__item {
542
+ display: flex;
543
+ align-items: center;
544
+ justify-content: space-between;
545
+ color: $mg-color-white;
546
+ cursor: pointer;
547
+ padding: $mg-spacing-100 $mg-spacing-250;
548
+
549
+ // Mobile-first: Start with mobile styles
550
+ background: $mg-color-interactive;
551
+ width: 100%;
552
+ border: none;
553
+ border-block-end: 1px solid $mg-color-white; // RTL-friendly
554
+
555
+ // Desktop: Remove mobile-specific styles
556
+ @media screen and (min-width: $mg-breakpoint-tablet) {
557
+ background: transparent;
558
+ border-block-end: none;
559
+ }
560
+
561
+ &:hover {
562
+ background: $mg-color-interactive-active;
563
+ color: $mg-color-white;
564
+ }
565
+
566
+ &:focus-visible {
567
+ outline: -webkit-focus-ring-color auto 2px;
568
+ outline-offset: -1px;
569
+ }
570
+
571
+ // Rotate arrow icon when section is expanded
572
+ &[aria-expanded="true"] {
573
+ .mg-icon-angle-circled-left {
574
+ transform: rotate(-90deg);
575
+ transition: transform 0.3s ease-in-out;
576
+ }
577
+ }
578
+
579
+ // Ensure smooth transition for icon default state
580
+ .mg-icon-angle-circled-left {
581
+ transition: transform 0.3s ease-in-out;
582
+ }
583
+ }
584
+
585
+ // RTL: Flip rotation direction
586
+ [dir="rtl"]
587
+ .mg-mega-sidebar-section__item[aria-expanded="true"]
588
+ .mg-icon-angle-circled-left {
589
+ transform: rotate(90deg);
590
+ }
591
+
592
+ .mg-mega-sidebar {
593
+ position: absolute;
594
+ overflow: auto;
595
+ background-color: $mg-color-interactive-active;
596
+ z-index: 10;
597
+
598
+ // Mobile-first: Full-width mobile sidebar
599
+ width: 100%;
600
+ height: auto;
601
+ max-height: 80vh;
602
+ top: -100%;
603
+ inset-inline: 0; // RTL-friendly
604
+ transition: top 0.4s ease-in-out;
605
+ box-shadow: 0 5px 8px -4px rgb(0 0 0 / 0.25);
606
+
607
+ &.mg-sidebar-open {
608
+ top: 0;
609
+ }
610
+
611
+ // Desktop: Side panel from end (right in LTR, left in RTL)
612
+ @media screen and (min-width: $mg-breakpoint-tablet) {
613
+ width: 300px;
614
+ height: 100vh;
615
+ top: 0;
616
+ inset-inline-start: auto;
617
+ inset-inline-end: 0; // RTL-friendly: appears from right in LTR, left in RTL
618
+ box-shadow: -5px 0 8px -4px rgb(0 0 0 / 0.25);
619
+ }
620
+ }
621
+
622
+ // RTL: Flip box shadow direction on desktop
623
+ [dir="rtl"] .mg-mega-sidebar {
624
+ @media screen and (min-width: $mg-breakpoint-tablet) {
625
+ box-shadow: 5px 0 8px -4px rgb(0 0 0 / 0.25);
626
+ }
627
+ }
628
+
629
+ .mg-mega-sidebar__list {
630
+ background: $mg-color-white;
631
+ display: flex;
632
+ flex-direction: column;
633
+ padding: 0;
634
+ margin-bottom: 0;
635
+ width: 100%;
636
+ position: relative;
637
+ inset-inline-end: auto; // RTL-friendly
638
+ }
639
+
640
+ .mg-mega-sidebar__section {
641
+ display: flex;
642
+ align-items: center;
643
+ justify-content: space-between;
644
+ padding: $mg-spacing-150 $mg-spacing-300;
645
+ color: $mg-color-white;
646
+ cursor: pointer;
647
+
648
+ &:hover {
649
+ background: $mg-color-interactive-active;
650
+ }
651
+ }
652
+
653
+ .mg-mega-topbar-mobile__icon-button {
654
+ // Mobile-first: Display by default
655
+ position: absolute;
656
+ inset-inline-end: 0; // RTL-friendly
657
+ background: rgb(0 0 0 / 0); // we let the menu items show through to advertise the contents
658
+ color: $mg-color-interactive;
659
+ font-size: mg-rem(20);
660
+ width: 100vw;
661
+ height: 100%;
662
+ padding: $mg-spacing-100;
663
+ border: none;
664
+ cursor: pointer;
665
+ align-items: start;
666
+ justify-content: start;
667
+ z-index: 14;
668
+ display: flex;
669
+
670
+ // Hide mobile button on desktop
671
+ @media screen and (min-width: $mg-breakpoint-tablet) {
672
+ display: none;
673
+ }
674
+
675
+ &:hover {
676
+ // background: $mg-color-interactive-active;
677
+ color: rgba($mg-color-interactive, 0.9);
678
+ }
679
+
680
+ .mg-mega-topbar {
681
+ position: relative;
682
+ }
683
+
684
+ &:has(.mg-icon-angle-circled-left) {
685
+ background: rgb(255 255 255 / 0.8);
686
+ color: $mg-color-interactive-active;
687
+ box-shadow: 0 0 4px rgb(0 0 0 / 0.2);
688
+ }
689
+ }
690
+
691
+ // Mobile sidebar (slides down/up from the top)
692
+ .mg-mega-mobile-sidebar {
693
+ // Mobile-first: Show on mobile, hide on desktop
694
+ width: 100%;
695
+ position: absolute;
696
+ top: 0;
697
+ inset-inline-start: 0; // RTL-friendly
698
+ z-index: 9;
699
+ display: block;
700
+ overflow: auto;
701
+ background-color: $mg-color-interactive;
702
+ max-height: 80vh;
703
+ height: 80vh;
704
+ transform: translateY(-100vh);
705
+ transition: transform 0.4s ease-in-out;
706
+ box-shadow: 0 5px 8px -4px rgb(0 0 0 / 0.25);
707
+
708
+ &.mg-mega-mobile-sidebar--open {
709
+ transform: translateY(calc(mg-rem(50) - 2px)); // mystery math?
710
+ }
711
+
712
+ // Desktop: Hide completely
713
+ @media screen and (min-width: $mg-breakpoint-tablet) {
714
+ display: none;
715
+ }
716
+ }
717
+
718
+ // Overlay backdrop (only shown when sidebar open)
719
+ .mg-mega-mobile-sidebar-overlay {
720
+ // Mobile-first: Show on mobile
721
+ display: block;
722
+ position: fixed;
723
+ inset: 0; // Already RTL-friendly logical property
724
+ background: rgb(0 0 0 / 0.4);
725
+ border: none;
726
+ padding: 0;
727
+ cursor: pointer;
728
+ z-index: 9; // just below sidebar which has 10
729
+
730
+ // Desktop: Hide
731
+ @media screen and (min-width: $mg-breakpoint-tablet) {
732
+ display: none;
733
+ }
734
+ }
735
+
736
+ // RTL: Flip hamburger shadow direction in branded variant
737
+ [dir="rtl"] .mg-mega-topbar--branded .mg-mega-topbar-mobile__icon-button {
738
+ box-shadow: 3px 0 6px -2px rgb(0 0 0 / 0.15);
739
+ }
740
+
741
+ [dir="rtl"] .mg-mega-topbar--branded .mg-mega-topbar-mobile__icon-button:has(.mg-icon-angle-circled-left) {
742
+ box-shadow: 3px 0 6px -2px rgb(0 0 0 / 0.15);
743
+ }
744
+
745
+ // Arabic
746
+ :lang(ar) {
747
+ .mg-mega-menu__item-link {
748
+ font-family: $mg-font-family-arabic-body;
749
+ }
750
+ }