added dark theme option. It ìs selected automagically based on system choiche of...
[theme-danix.xyz.git] / assets / sass / base / _page.scss
1 ///
2 /// Forty by HTML5 UP
3 /// html5up.net | @ajlkn
4 /// Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
5 ///
6
7 /* Basic */
8
9 // MSIE: Required for IEMobile.
10 @-ms-viewport {
11 width: device-width;
12 }
13
14 // MSIE: Prevents scrollbar from overlapping content.
15 body {
16 -ms-overflow-style: scrollbar;
17 }
18
19 // Ensures page width is always >=320px.
20 @include breakpoint('<=xsmall') {
21 html, body {
22 min-width: 320px;
23 }
24 }
25
26 // Set box model to border-box.
27 // Based on css-tricks.com/inheriting-box-sizing-probably-slightly-better-best-practice
28 html {
29 box-sizing: border-box;
30 }
31
32 *, *:before, *:after {
33 box-sizing: inherit;
34 }
35
36 body {
37 background: _palette_light(bg);
38 @media screen and (prefers-color-scheme: dark) {
39 background: _palette_dark(bg);
40 }
41
42 // Stops initial animations until page loads.
43 &.is-preload {
44 *, *:before, *:after {
45 @include vendor('animation', 'none !important');
46 @include vendor('transition', 'none !important');
47 }
48 }
49
50 }