summaryrefslogtreecommitdiff
path: root/css/navBar.scss
blob: 9eba669f4f41302bad621bd2ef54629c4155a9c3 (plain) (blame)
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
#navBar {
	$gap: 1rem;

	align-items:     center;
	display:         flex;
	height:          calc($gap * 2 + var(--hamburgerWidth));
	justify-content: space-between;
	padding:         $gap;
	position:        absolute;
	top:             0;
	width:           100%;

	section {
		display: flex;
		flex:    1;
		gap:     $gap;

		&:first-of-type {
			justify-content: start;
		}

		&:last-of-type {
			justify-content: end;
		}

		a {
			text-decoration-color: #00000000;
			transition:            opacity $slideDuration, text-decoration-color 0.125s;

			@media (orientation: portrait) or (pointer: coarse) {
				display: none;
			}

			&:hover {
				text-decoration-color: var(--textColour);
			}

			&.hidden:not(#home) {
				opacity:        0;
				pointer-events: none;
			}
		}

		#hamburger {
			aspect-ratio:     1;
			background-color: var(--textColour);
			cursor:           pointer;
			mask-image:       url("/svg/hamburger.svg");
			mask-size:        cover;
			width:            var(--hamburgerWidth);
		}

		body[data-page = "achernar"] & {
			a, div {
				@media not (prefers-reduced-motion) {
					mix-blend-mode: difference;
				}
			}
		}
	}
}