1+ @use " src/styles/mixins" as * ;
2+
3+ /*
4+ * Section 1 (Hero)
5+ */
6+
7+ :global {
8+ // Outer section
9+ #hero-section {
10+ position : relative ;
11+ overflow : hidden ;
12+ block-size : 75vh ;
13+ min-block-size : 584px ;
14+ max-block-size : 1024px ;
15+ border-block-end : 1px solid var (--fds-divider-stroke-default );
16+
17+ // Inner Section
18+ .page-section-inner {
19+ position : relative ;
20+ display : grid ;
21+ grid-template-columns : 1fr 1.5fr ;
22+ align-items : center ;
23+ gap : 4rem ;
24+ }
25+
26+ :global {
27+ .split- button {
28+ display : flex ;
29+ position : relative ;
30+
31+ .button :first-of-type {
32+ border-radius : var (--fds-control-corner-radius ) 0 0 var (--fds-control-corner-radius );
33+ border-inline-end : 1px solid var (--fds-divider-stroke-default );
34+ }
35+
36+ .menu-flyout-wrapper {
37+ display : contents ;
38+ .button {
39+ border-radius : 0 var (--fds-control-corner-radius ) var (--fds-control-corner-radius ) 0 ;
40+ block-size : 100% ;
41+ padding-inline : 8px ;
42+ }
43+ }
44+ }
45+ }
46+
47+ // Custom button styling
48+ // Applied on download and source buttons respectively
49+ :global {
50+ .button {
51+ padding : 7px 12px ;
52+ cursor : pointer ;
53+
54+ svg {
55+ @include icon ($size : 14px );
56+ }
57+ }
58+
59+ .style-standard .hero-button-inner {
60+ color : var (--fds-text-secondary );
61+
62+ h5 {
63+ color : var (--fds-text-primary );
64+ }
65+ }
66+ }
67+
68+ @keyframes rainbow-background-hue-rotate {
69+ 0% {
70+ filter : none ;
71+ }
72+ 50% {
73+ filter : hue-rotate (180deg );
74+ }
75+ to {
76+ filter : none ;
77+ }
78+ }
79+
80+ // Backdrop canvas
81+ .rainbow-background {
82+ position : absolute ;
83+ z-index : -1 ;
84+ background : 800% 800% /* pos */
85+ linear-gradient (
86+ to bottom right ,
87+ hsl (133 , 67% , 59% ),
88+ hsl (172 , 100% , 42% ),
89+ hsl (202 , 97% , 45% ),
90+ var (--fds-solid-background-base )
91+ );
92+ animation : rainbow- background- hue- rotate 15s infinite linear ,
93+ scroll- gradient 15s infinite linear ;
94+ inset-inline-end : 0 ;
95+ inset-block-end : 0 ;
96+ inline-size : 60vw ;
97+ min-inline-size : 100vh ;
98+ block-size : 100% ;
99+
100+ mask : url (" /ui/hero-mask.png" ) bottom / cover no-repeat ;
101+
102+ @media (prefers-color-scheme : light ) {
103+ opacity : 0.5 ;
104+ }
105+
106+ @media screen and (width < 1024px ) {
107+ inline-size : 100% ;
108+ transform : rotate (90deg ) scale (1.5 );
109+ }
110+
111+ @media screen and (width < 648px ) {
112+ block-size : 60vh ;
113+ mask-size : 100% 100% ;
114+ }
115+ }
116+ }
117+ }
118+
119+ // Hero container elements
120+ .hero- {
121+ // Left container
122+ & left {
123+ @include flex ($direction : column , $justify : center );
124+ flex : 1 1 auto ;
125+ }
126+
127+ // Right container
128+ & right {
129+ @include flex ($align : center );
130+ block-size : 100% ;
131+
132+ img {
133+ position : absolute ;
134+ inline-size : auto ;
135+ max-inline-size : 100% ;
136+ border : 1px solid var (--fds-surface-stroke-default );
137+ border-radius : calc (var (--fds-overlay-corner-radius ) / 1.5 );
138+ background-color : hsl (var (--mica-tint ), calc (var (--mica-tint-opacity ) / 1.5 ));
139+ box-shadow : var (--fds-dialog-shadow );
140+ overflow : hidden ;
141+ user-select : none ;
142+ inset-inline-end : 0 ;
143+ block-size : auto ;
144+ max-block-size : 100% ;
145+ -webkit-user-drag : none ;
146+ aspect-ratio : 1280 / 960 ;
147+ backdrop-filter : blur (60px ) saturate (150% );
148+
149+ @media screen and (width > 2048px ) {
150+ border-radius : var (--fds-overlay-corner-radius );
151+ }
152+ }
153+ }
154+
155+ // Inner hero buttons
156+ & button-inner {
157+ @include flex ($direction : column , $align : start );
158+ margin-inline-start : 8px ;
159+ font-size : 1.1rem ;
160+ line-height : normal ;
161+
162+ h5 {
163+ margin : 0 ;
164+ font-size : 1.25rem ;
165+ font-weight : 600 ;
166+ }
167+ }
168+
169+ // Hero image container
170+ & image-container {
171+ @include flex ($align : center , $justify : center );
172+ position : relative ;
173+ inline-size : 100% ;
174+ block-size : 100% ;
175+ max-block-size : 768px ;
176+ }
177+ }
178+
179+ // Hero section small device support
180+ @media screen and (width < 1024px ) {
181+ :global {
182+ // Remove height constraints on outer container
183+ #hero- section {
184+ block-size : auto ;
185+ max-block-size : unset ;
186+
187+ // Position inner containers vertically
188+ .page-section-inner {
189+ grid-template-columns : auto ;
190+ }
191+ }
192+ }
193+
194+ .hero- {
195+ // Centrally align content in the left container
196+ & left {
197+ align-items : center ;
198+ text-align : center ;
199+
200+ .buttons-spacer {
201+ justify-content : center ;
202+ }
203+ }
204+
205+ // Properly position hero image
206+ & right img {
207+ position : relative ;
208+ inline-size : 100% ;
209+ max-inline-size : 708px ;
210+ block-size : auto ;
211+ }
212+ }
213+ }
0 commit comments