_typography.scss 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257
  1. // Typography
  2. body {
  3. // для прижатого к низу футера
  4. display: flex;
  5. flex-direction: column;
  6. min-height: 100vh;
  7. margin:0;
  8. padding:0;
  9. font-family: var(--default-font-family), Helvetica, Arial, sans-serif;
  10. font-weight: 400;
  11. font-size: var(--fz-default);
  12. font-style: normal;
  13. font-weight: 400;
  14. line-height: var(--lh-default);
  15. min-width: 360px;
  16. color: var(--text-color);
  17. position: relative;
  18. scroll-behavior: smooth; // плавный скролл
  19. -webkit-font-smoothing: antialiased;
  20. -moz-osx-font-smoothing: grayscale;
  21. text-rendering: optimizeLegibility; //сглаживание шрифтов
  22. }
  23. // default typography styles
  24. h1 {
  25. font-family: var(--heading-font-family);
  26. font-weight: 600;
  27. font-size: var(--h1);
  28. line-height: 106%;
  29. text-transform: uppercase;
  30. }
  31. h2 {
  32. font-family: var(--heading-font-family);
  33. font-weight: 600;
  34. font-size: var(--h2);
  35. line-height: 125%;
  36. text-transform: uppercase;
  37. }
  38. h3 {
  39. font-family: var(--heading-font-family);
  40. font-weight: 600;
  41. font-size: var(--h3);
  42. line-height: 130%;
  43. }
  44. h4 {
  45. font-family: var(--heading-font-family);
  46. font-weight: 600;
  47. font-size: var(--h4);
  48. line-height: 133%;
  49. }
  50. h5 {
  51. font-family: var(--heading-font-family);
  52. font-weight: 600;
  53. font-size: var(--m);
  54. line-height: 135%;
  55. }
  56. h6 {
  57. font-family: var(--heading-font-family);
  58. font-weight: 900;
  59. font-size: var(--m);
  60. line-height: 140%;
  61. }
  62. h1, h2, h3, h4, h5, h6{
  63. margin:32px 0 20px 0;
  64. @include mobile{
  65. margin:24px 0 12px 0;
  66. }
  67. }
  68. // text style
  69. .text{
  70. & > h1:first-child,
  71. & > h2:first-child,
  72. & > h3:first-child,
  73. & > h4:first-child,
  74. & > h5:first-child,
  75. & > h6:first-child{
  76. margin-top:0;
  77. }
  78. p{
  79. margin-bottom:24px;
  80. @include mobile{
  81. margin-bottom:16px;
  82. }
  83. &:last-child{
  84. margin-bottom:0;
  85. }
  86. }
  87. a{
  88. color:var(--color-link-text);
  89. text-decoration:underline;
  90. text-underline-offset: 3px;
  91. text-decoration-thickness: 1px;
  92. &:hover{
  93. text-decoration:none;
  94. color:var(--color-theme-red);
  95. }
  96. }
  97. // list style ol ul
  98. ol, ul{
  99. margin:24px 0;
  100. list-style-position: inside;
  101. @include mobile{
  102. margin:12px 0;
  103. padding-left:8px;
  104. }
  105. li{
  106. margin:12px 0;
  107. margin-left:32px;
  108. @include mobile{
  109. margin-left:16px;
  110. }
  111. }
  112. }
  113. // list style ul
  114. ul{
  115. list-style:disc;
  116. }
  117. // list style ol
  118. ol{
  119. list-style:decimal;
  120. }
  121. img{
  122. max-width:100%;
  123. height:auto;
  124. border-radius: 12px;
  125. }
  126. // блок врапер для скролла таблицы
  127. .table-wrapper-scroll{
  128. margin:30px 0;
  129. background: var(--table-bg-color);
  130. border: 1px solid var(--content-border-color);
  131. border-radius: 9px;
  132. overflow: hidden;
  133. @include mobile-sm{
  134. overflow-x: auto;
  135. margin:20px 0;
  136. &::-webkit-scrollbar {
  137. height: 6px;
  138. }
  139. &::-webkit-scrollbar-track {
  140. background: var(--table-bg-color);
  141. border-radius: 9px;
  142. }
  143. &::-webkit-scrollbar-thumb {
  144. background: var(--content-border-color);
  145. border-radius: 9px;
  146. &:hover {
  147. background: var(--accent-color);
  148. }
  149. }
  150. }
  151. // &.has-caption{
  152. // padding-top:25px;
  153. // }
  154. }
  155. // дополнительный блок врапер для стилизации таблицы (border-radius gradient)
  156. .table-wrapper{
  157. //padding:1px;
  158. border-radius:9px;
  159. &.large-table{
  160. @include mobile-sm{
  161. width:640px;
  162. }
  163. }
  164. }
  165. // стили таблицы по умолчанию
  166. table{
  167. margin:0;
  168. position:relative;
  169. width:100%;
  170. //table-layout: fixed;
  171. table-layout: auto;
  172. border-collapse: collapse;
  173. border-radius:9px;
  174. overflow:hidden;
  175. background: var(--table-bg-color);
  176. thead{
  177. th, td{
  178. padding:12px;
  179. text-align: center;
  180. font-size: 16px;
  181. font-style: normal;
  182. font-weight: 600;
  183. line-height:1.2em;
  184. vertical-align: middle;
  185. background: var(--table-header-color);
  186. border: 1px solid var(--content-border-color);
  187. @include mobile-sm{
  188. vertical-align: middle;
  189. font-size:13px;
  190. padding:8px;
  191. }
  192. }
  193. }
  194. tr:first-child{
  195. th{
  196. padding:12px;
  197. text-align: center;
  198. font-size: 16px;
  199. font-style: normal;
  200. font-weight: 600;
  201. line-height:1.2em;
  202. vertical-align: middle;
  203. background: var(--table-header-color);
  204. border: 1px solid var(--content-border-color);
  205. @include mobile-sm{
  206. vertical-align: middle;
  207. font-size:13px;
  208. padding:8px;
  209. }
  210. }
  211. &:has(th){
  212. overflow:hidden;
  213. height: auto !important;
  214. }
  215. }
  216. tbody{
  217. tr{
  218. border: 1px solid var(--content-border-color);
  219. &:nth-child(even){
  220. background: rgba(var(--table-header-color-rgb, 42, 42, 42), 0.1);
  221. }
  222. }
  223. td{
  224. padding:12px;
  225. vertical-align: middle;
  226. word-wrap: break-word;
  227. border: 1px solid var(--content-border-color);
  228. @include tablet{
  229. font-size: 14px;
  230. font-style: normal;
  231. font-weight: 400;
  232. line-height: 16px;
  233. }
  234. @include mobile-sm{
  235. font-size:13px;
  236. padding:8px;
  237. }
  238. }
  239. }
  240. }
  241. }