File size: 2,473 Bytes
32dba06
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
.modal {
  align-items: center;
  display: none;
  height: 100%;
  left: 0;
  overflow: auto;
  padding: var(--space-medium);
  position: fixed;
  top: 0;
  width: 100%;
}

.modal[open] {
  display: grid;
}

.modal:modal {
  max-height: none;
  max-width: none;
}

.modal::backdrop {
  background: none;
}

.modal__backdrop {
  backdrop-filter: blur(1em);
  -webkit-backdrop-filter: blur(1em);
  background: rgba(var(--rgb-white), 0.8);
  cursor: zoom-out;
  inset: 0;
  position: fixed;
  user-select: none;
  -webkit-user-select: none;
}

.modal__container {
  display: grid;
  position: relative;
}

.modal__close {
  background: url('/assets/images/general/icon-close.svg') center center/0.425em auto no-repeat var(--color-black);
  border-radius: 100%;
  cursor: pointer;
  height: 1.2em;
  position: absolute;
  right: -0.6em;
  top: -0.6em;
  width: 1.2em;
}

.modal__image,
.modal__video {
  background: var(--color-white);
  border-radius: 0.2em;
  box-shadow: var(--box-shadow);
  display: grid;
  overflow: hidden;
  user-select: none;
  -webkit-user-select: none;
}

.modal__image {
  cursor: zoom-out;
}

.modal__video {
  position: relative;
}

.modal__video button {
  cursor: pointer;
  display: grid;
  inset: 0;
  place-items: center;
  position: absolute;
}

.modal__video button:before,
.modal__video button:after {
  content: '';
  pointer-events: none;
  position: absolute;
}

.modal__video button:before {
  background: linear-gradient(180deg, rgba(var(--rgb-black), 0.6) 0, rgba(var(--rgb-black), 0.15) 80%);
  inset: 0;
  transition: opacity var(--transition-slow);
}

.modal__video button:after {
  background: url('/assets/images/general/icon-video.svg') center center/0.8em auto no-repeat var(--color-white);
  border-radius: 100%;
  box-shadow: var(--box-shadow-play);
  height: 2.2em;
  width: 2.2em;
}



.modal__video--playing button {
  display: none;
}



@media(hover: hover) {

  .modal__close {
    transition: transform var(--transition);
    will-change: transform;
  }

  .modal__close:hover {
    transform: scale(1.06);
  }

  .modal__video button:before {
    transition: opacity var(--transition);
  }

  .modal__video button:after {
    transition: transform var(--transition);
    will-change: transform;
  }

  .modal__video button:hover:before {
    opacity: 0.9;
  }

  .modal__video button:hover:after {
    transform: scale(1.03);
  }

}



@media(min-width: 64em) {

  .modal {
    padding: var(--space-neutral);
  }

}