web/src/components/things/service-card.scss
110 lines · 2222 bytes
1.service {
2 display: flex;
3 flex-direction: column;
4 padding: 1rem;
5 border: 2px solid var(--box-outline);
6 box-shadow: 6px 6px 0 var(--box-outline);
7 background: var(--accent-fg);
8 border-radius: var(--curve-sm);
9 position: relative;
10 overflow: hidden;
11
12 .service-head {
13 display: flex;
14 align-items: center;
15 gap: 0.5rem;
16 h4 {
17 margin: 0;
18 font-size: 1.4rem;
19 color: var(--foreground);
20 }
21 p {
22 margin: 0;
23 font-size: 1rem;
24 opacity: 0.7;
25 }
26 a {
27 text-decoration: none;
28 }
29 h4 {
30 text-decoration: none;
31 position: relative;
32 &:after {
33 background: none repeat scroll 0 0 transparent;
34 bottom: 0;
35 content: "";
36 display: block;
37 height: 3px;
38 left: 50%;
39 position: absolute;
40 background: var(--accent-3);
41 transition: width 0.2s ease 0s, left 0.2s ease 0s;
42 width: 0;
43 }
44 &:hover:after {
45 width: 100%;
46 left: 0;
47 }
48 }
49 }
50
51 .save-listing {
52 position: absolute;
53 top: 0.5rem;
54 right: 0.5rem;
55 }
56
57 .service-body {
58 display: flex;
59 align-items: center;
60 gap: 0.5rem;
61 img {
62 border-radius: var(--curve-sm);
63 font-size: 0.6rem;
64 color: var(--accent);
65 }
66 :global(p) {
67 display: -webkit-box;
68 -webkit-line-clamp: 3;
69 -webkit-box-orient: vertical;
70 overflow: hidden;
71 margin: 0.5rem 0;
72 width: calc(100% - 2rem);
73 overflow-x: hidden;
74 }
75 }
76
77 .service-links {
78 display: flex;
79 gap: 0.5rem;
80 justify-content: space-between;
81 a {
82 color: var(--accent-3);
83 font-size: 0.8rem;
84 display: inline-flex;
85 align-items: center;
86 gap: 0.25rem;
87 opacity: 0.85;
88 text-decoration: none;
89 max-width: 50%;
90 min-width: 25%;
91 &:not(:last-child) {
92 margin-right: 0.5rem;
93 }
94 &:hover {
95 text-decoration: underline;
96 opacity: 1;
97 }
98 :global(svg) {
99 width: 1rem;
100 height: 1rem;
101 }
102 span {
103 max-width: calc(100% - 1rem);
104 text-overflow: ellipsis;
105 white-space: nowrap;
106 overflow: hidden;
107 }
108 }
109 }
110}