summaryrefslogtreecommitdiff
path: root/_sass/common/components/_item.scss
blob: a1a9fd0fb82afafb486d82fbfdfe2bc387b6eeb0 (plain)
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
.item {
  @include flexbox();
  @include media-breakpoint-down(md) {
    @include flex-direction(column);
  }
}

.item__image {
  margin-right: map-get($spacers, 3);
  & + .item__content {
    & > :first-child {
      margin-top: 0;
      & > :first-child {
        margin-top: 0;
      }
    }
  }
  @include media-breakpoint-down(md) {
    margin-right: 0;
  }
}

.item__content {
  @include flex(1);
  min-width: 0;
}

a > .item__header, a.item__header, .item__header > a {
  @include link-colors($text-color-d, $main-color-1);
}

.item__meta {
  color: $text-color-l;
}

.item__description {
  &, .article__content {
    font-size: map-get($base, font-size-sm);
    line-height: map-get($base, line-height);
    @include block-elements() {
      margin-top: map-get($spacers, 2);
      margin-bottom: map-get($spacers, 2);
    }
    @include heading-elements() {
      margin-top: map-get($spacers, 3);
    }
    h1, h2, h3 {
      color: $text-color;
    }
    h1, h2 {
      padding: 0;
      border: none;
    }
    h1 {
      font-size: map-get($base, font-size-h1-xs);
    }
    h2 {
      font-size: map-get($base, font-size-h2-xs);
    }
    h3 {
      font-size: map-get($base, font-size-h3-xs);
    }
    h4 {
      font-size: map-get($base, font-size-h4-xs);
    }
    h5 {
      font-size: map-get($base, font-size-h5-xs);
    }
    h6 {
      font-size: map-get($base, font-size-h6-xs);
    }
    img {
      max-height: 32rem;
      @include media-breakpoint-down(md) {
        max-height: 14rem;
      }
    }
  }
}

.items {
  & > .item {
    &:not(:last-child) {
      margin-bottom: map-get($spacers, 2);
    }
  }
}

.items--divided {
  & > .item {
    &:not(:first-child) {
      padding-top: map-get($spacers, 4);
    }
    &:not(:last-child) {
      padding-bottom: map-get($spacers, 4);
      @include split-line(bottom);
    }
    list-style-type: none;
  }
}