Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.
 
 
 
 

418 righe
8.3 KiB

  1. @use '../../_global/styles/mixins' as *;
  2. @use '../../_global/styles/vars' as *;
  3. .teaser {
  4. //--hero-background: var(--swatches-neutrals-white);
  5. position: relative;
  6. display: flex;
  7. flex-direction: column;
  8. height: 100%;
  9. text-decoration: none;
  10. font-size: var(--font-size-small);
  11. container-type: inline-size;
  12. &::before {
  13. content: '';
  14. @include full-size;
  15. margin: -6px;
  16. border-radius: var(--border-radius-xs);
  17. transition: 0.2s ease;
  18. }
  19. &:focus {
  20. outline: none;
  21. }
  22. &.focus-visible:focus::before {
  23. @include focus-standalone;
  24. }
  25. &:focus-visible::before, &.-moz-focusring::before {
  26. @include focus-standalone;
  27. }
  28. &.text {
  29. margin-bottom: 0;
  30. }
  31. .teaser--link {
  32. position: absolute;
  33. left: 0;
  34. top: 0;
  35. width: 100%;
  36. height: 100%;
  37. z-index: 10;
  38. }
  39. .image-box {
  40. position: relative;
  41. display: block;
  42. border-radius: var(--border-radius-xs);
  43. background-color: var(--color-button-tertiary-background);
  44. overflow: hidden;
  45. flex-grow: 0;
  46. flex-shrink: 0;
  47. &::before {
  48. content: "";
  49. position: relative;
  50. display: block;
  51. padding-top: 66.6667%;
  52. margin-bottom: 7px;
  53. }
  54. &::after {
  55. content: "";
  56. position: absolute;
  57. left: 0;
  58. bottom: 0;
  59. width: 100%;
  60. display: block;
  61. height: 8px;
  62. background-color: var(--color-decoration);
  63. transition: 0.3s ease;
  64. z-index: 1;
  65. border-bottom-right-radius: 4px;
  66. border-bottom-left-radius: 4px;
  67. }
  68. &.chart {
  69. display: flex;
  70. align-items: center;
  71. justify-content: center;
  72. @include gradient;
  73. }
  74. }
  75. img {
  76. position: absolute;
  77. top: 0;
  78. left: 0;
  79. max-width: 100%;
  80. width: 100%;
  81. height: calc(100% - 7px);
  82. object-fit: cover;
  83. opacity: 1;
  84. transition: 0.3s linear;
  85. &.loading {
  86. opacity: 0;
  87. }
  88. }
  89. .copyright {
  90. @include copyright;
  91. bottom: 8px;
  92. }
  93. .picto-box {
  94. position: absolute;
  95. left: 50%;
  96. top: 50%;
  97. transform: translate(-50%,-50%);
  98. .icon {
  99. width: 90px;
  100. height: 90px;
  101. overflow: hidden;
  102. position: relative;
  103. margin: 0 auto;
  104. @media(min-width: 568px) {
  105. width: 100px;
  106. height: 100px;
  107. }
  108. &:before {
  109. display: block;
  110. position: absolute;
  111. left: 0;
  112. top: 0;
  113. font-family: "Pictograms", sans-serif;
  114. color: var(--color-text);
  115. font-size: 90px;
  116. line-height: 1;
  117. @media(min-width: 568px) {
  118. font-size: 100px;
  119. }
  120. }
  121. }
  122. .picto-title {
  123. @include h3;
  124. margin: 10px 0 0 0;
  125. width: calc(100vw - 80px);
  126. overflow: hidden;
  127. height: 38px;
  128. display: block;
  129. font-weight: 400 !important;
  130. color: var(--color-text) !important;
  131. text-decoration-color: transparent !important;
  132. text-align: center;
  133. @media(max-width: 999px) {
  134. font-size: 28px;
  135. height: 32px;
  136. }
  137. }
  138. }
  139. &.pictoHero {
  140. .picto-box {
  141. margin-top: -20px;
  142. .icon {
  143. @media(min-width: 568px) {
  144. width: 150px;
  145. height: 150px;
  146. }
  147. &:before {
  148. @media(min-width: 568px) {
  149. font-size: 150px;
  150. }
  151. }
  152. }
  153. }
  154. }
  155. .chart-title {
  156. @include h3;
  157. display: block;
  158. font-weight: 500 !important;
  159. padding: 30px;
  160. margin: 0 0 0.4em;
  161. color: var(--color-text) !important;
  162. text-decoration-color: transparent !important;
  163. text-align: center;
  164. @media(max-width: 999px) {
  165. font-size: 28px;
  166. margin-bottom: 0;
  167. padding: 20px;
  168. }
  169. }
  170. .kicker + .text-box {
  171. margin-top: 0;
  172. border-top: 8px solid var(--color-decoration);
  173. }
  174. .text-box {
  175. position: relative;
  176. &:not(:last-child) {
  177. padding-bottom: 20px;
  178. > p:last-child {
  179. margin-bottom: 0;
  180. &::after {
  181. content: '';
  182. position: relative;
  183. float: right;
  184. height: 0.75em;
  185. display: inline-block;
  186. width: 150px;
  187. }
  188. }
  189. }
  190. }
  191. .title {
  192. text-decoration: underline;
  193. text-underline-offset: 0.07em;
  194. text-decoration-thickness: 0.08em;
  195. margin: 0.5em 0;
  196. }
  197. &:has(.teaser--link):hover {
  198. .image-box::after {
  199. height: var(--border-width-hover);
  200. }
  201. .copyright {
  202. bottom: 14px;
  203. @media(max-width: 767px) {
  204. bottom: 10px;
  205. }
  206. }
  207. }
  208. }
  209. [date-type='hero'], .teaser.hero, .teaser.pictoHero {
  210. .image-box ~ .text-box {
  211. padding-top: 0.9em;
  212. .title {
  213. position: absolute;
  214. bottom: 100%;
  215. z-index: 1;
  216. background-color: var(--swatches-neutrals-white);
  217. //background-color: var(--hero-background);
  218. margin-right: 40px;
  219. padding-top: 0.4em;
  220. padding-right: 0.8em;
  221. margin-bottom: -0.05em;
  222. }
  223. }
  224. }
  225. .col.extern, .col.download, .col.intranet, .col.extranet, .col.gallery, .col.interaction, .col.video,
  226. .teaser.extern, .teaser.gallery, .teaser.interaction, .teaser.video, .teaser.download, .teaser.intranet, .teaser.extranet {
  227. &:before {
  228. display: none;
  229. }
  230. .title:after {
  231. @include icon-small-stern;
  232. font-family: 'Icons', sans-serif;
  233. position: relative;
  234. font-size: var(--icon-size-small);
  235. line-height: 1;
  236. text-decoration: none;
  237. display: inline-block;
  238. vertical-align: top;
  239. margin-left: 0.2em;
  240. @media(min-width: 983px) {
  241. margin-top: 0.1rem;
  242. }
  243. @media(min-width: 1340px) {
  244. margin-top: 0.27rem;
  245. }
  246. }
  247. }
  248. .col.extern .title:after,
  249. .teaser.extern .title:after {
  250. @include icon-small-link-external;
  251. }
  252. .col.download .title:after,
  253. .teaser.download .title:after {
  254. @include icon-small-download;
  255. }
  256. .col.intranet .title:after,
  257. .teaser.intranet .title:after {
  258. @include icon-small-schloss;
  259. }
  260. .col.gallery .title:after,
  261. .teaser.gallery .title:after {
  262. @include icon-galerie-small;
  263. }
  264. .col.interaction .title:after,
  265. .teaser.interaction .title:after {
  266. @include icon-interaction-small;
  267. }
  268. .col.video .title:after,
  269. .teaser.video .title:after {
  270. @include icon-video-small;
  271. }
  272. @media(min-width: 568px) {
  273. .teaser[data-image-size="l"],
  274. .teaser[data-image-size="m"],
  275. .teaser[data-image-size="s"] {
  276. .reading-time {
  277. position: absolute;
  278. right: 0;
  279. bottom: 0;
  280. width: auto;
  281. }
  282. }
  283. }
  284. .teaser[data-image-size="l"] .like-h4,
  285. .teaser[data-image-size="m"] .like-h4,
  286. .teaser[data-image-size="s"] .like-h4,
  287. .teaser[data-image-size="l"] .like-h4.title,
  288. .teaser[data-image-size="m"] .like-h4.title,
  289. .teaser[data-image-size="s"] .like-h4.title {
  290. @include h2;
  291. text-decoration-thickness: 0.07em;
  292. margin-top: 0;
  293. }
  294. @media(min-width: 568px) {
  295. [date-type='fullwidth'], .teaser.fullwidth, .teasers[data-items="1"] {
  296. display: block;
  297. &::after {
  298. content: '';
  299. display: block;
  300. clear: both;
  301. }
  302. .title {
  303. @include h4;
  304. margin-top: 0.25em;
  305. }
  306. .image-box {
  307. float: left;
  308. }
  309. .kicker, .text-box {
  310. float: right;
  311. }
  312. &[data-image-size='s'] {
  313. .image-box::before {
  314. padding-top: 100%;
  315. }
  316. }
  317. &[data-image-size='l'] {
  318. .image-box::before {
  319. padding-top: 55%;
  320. }
  321. }
  322. @media(max-width: 999px) {
  323. :has(> .image-box) .kicker,
  324. :has(> .image-box) .text-box,
  325. :has(> .image-box) .image-box {
  326. width: calc(50% - var(--col-padding));
  327. @media (min-width: 568px) {
  328. max-width: calc(50% - var(--col-padding));
  329. min-width: calc(50% - var(--col-padding));
  330. }
  331. }
  332. }
  333. @media(min-width: 1000px) {
  334. &[data-image-size='s'] {
  335. .image-box {
  336. width: calc((100% + var(--col-padding) * 2) / 12 * 5 - var(--col-padding) * 2);
  337. }
  338. .kicker, .text-box {
  339. width: calc((100% + var(--col-padding) * 2) / 12 * 7 - var(--col-padding) * 2);
  340. }
  341. }
  342. &[data-image-size='m'] {
  343. .image-box, .kicker, .text-box {
  344. width: calc(50% - var(--col-padding));
  345. }
  346. }
  347. &[data-image-size='l'] {
  348. .image-box {
  349. width: calc((100% + var(--col-padding) * 2) * 2 / 3 - var(--col-padding) * 2);
  350. }
  351. .kicker, .text-box {
  352. width: calc((100% + var(--col-padding) * 2) / 3 - var(--col-padding) * 2);
  353. }
  354. }
  355. }
  356. }
  357. }
  358. [data-background='lightblue'] .teaser {
  359. //--hero-background: var(--swatches-primary-100);
  360. .image-box {
  361. background-color: rgba(#fff, 0.4);
  362. }
  363. }