web/src/components/things/service-card.scss

83 lines · 1719 bytes

 1@use '../../styles/mixins' as *;
 2
 3.service {
 4  display: flex;
 5  flex-direction: column;
 6  padding: var(--space-md);
 7  border: var(--border-heavy);
 8  box-shadow: var(--shadow-lg);
 9  background: var(--accent-fg);
10  border-radius: var(--curve-sm);
11  position: relative;
12  overflow: hidden;
13
14  .service-head {
15    display: flex;
16    align-items: center;
17    gap: var(--space-sm);
18    h4 {
19      margin: 0;
20      font-size: var(--text-lg);
21      color: var(--foreground);
22      text-decoration: none;
23      @include underline-hover(var(--accent-3), 3px, 100%, 0.2s);
24    }
25    p {
26      margin: 0;
27      font-size: var(--text-base);
28      opacity: var(--opacity-soft);
29    }
30    a {
31      text-decoration: none;
32    }
33  }
34
35  .save-listing {
36    position: absolute;
37    top: var(--space-sm);
38    right: var(--space-sm);
39  }
40
41  .service-body {
42    display: flex;
43    align-items: center;
44    gap: var(--space-sm);
45    :global(p) {
46      @include line-clamp(3);
47      margin: var(--space-sm) 0;
48      width: calc(100% - 2rem);
49    }
50  }
51
52  .service-links {
53    display: flex;
54    gap: var(--space-sm);
55    justify-content: space-between;
56    a {
57      color: var(--accent-3);
58      font-size: var(--text-sm);
59      display: inline-flex;
60      align-items: center;
61      gap: var(--space-xs);
62      opacity: var(--opacity-subtle);
63      text-decoration: none;
64      max-width: 50%;
65      min-width: 25%;
66      &:not(:last-child) {
67        margin-right: var(--space-sm);
68      }
69      &:hover {
70        text-decoration: underline;
71        opacity: 1;
72      }
73      :global(svg) {
74        width: 1rem;
75        height: 1rem;
76      }
77      span {
78        max-width: calc(100% - 1rem);
79        @include truncate;
80      }
81    }
82  }
83}