/* Lantbruksnytt Maskintest-puff. Måtten är tagna från den tidigare GIF:en (800 × 390) och anges i procent
   av bredden (cqw), så att puffen ser likadan ut i alla storlekar. Typsnitt: Chakra Petch Bold, som i GIF:en
   (OFL, fonts/OFL.txt; bara latinska tecken, ca 11 kB). */
@font-face { font-family: "LNMTP Chakra Petch"; src: url("fonts/chakra-petch-bold.woff") format("woff"); font-weight: 700; font-style: normal; font-display: swap; }
.lnmtp {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 800 / 390;
  overflow: hidden;
  container-type: inline-size;
  background: #fed009;
  color: inherit;
  text-decoration: none;
}
.lnmtp:hover, .lnmtp:focus { text-decoration: none; }
.lnmtp { border-radius: var(--radius, 0); }   /* Som temats andra bildwidgetar (ln-widget-fill). */
.lnmtp img { display: block; max-width: none; border-radius: 0; }
.lnmtp .lnmtp__start, .lnmtp .lnmtp__test, .lnmtp .lnmtp__img {   /* Dubbel klass: går före temats .ln-widget-fill img. */
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.lnmtp .lnmtp__img { object-fit: cover; }

/* Bild 2: testet. Visas varannan period om tre sekunder (som GIF:en). */
.lnmtp__test { opacity: 0; animation: lnmtp-swap 6s infinite; }
@keyframes lnmtp-swap {
  0%, 47% { opacity: 0; }
  50%, 97% { opacity: 1; }
  100% { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .lnmtp__test { animation: none; opacity: 1; }
}

.lnmtp__box {
  position: absolute;
  left: 0;
  bottom: 2.4cqw;
  box-sizing: border-box;
  width: max-content;   /* Rutan följer texten (längsta raden). */
  max-width: 100%;
  min-height: 15cqw;
  padding: 1.4cqw 4cqw 1.4cqw 2.75cqw;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1.8cqw;
  background: #fed009;
  font-family: "LNMTP Chakra Petch", "Archivo", "Arial Narrow", system-ui, sans-serif;
  line-height: 1;
  text-align: left;
}
.lnmtp__label {
  color: #fff;
  font-size: 5.1cqw;
  font-weight: 700;
  text-transform: uppercase;
  white-space: nowrap;
}
.lnmtp__dark { color: #111; }   /* TEST i MASKINTEST, som loggan. */
.lnmtp__title {
  color: #111;
  font-size: 4.4cqw;
  font-weight: 700;
  line-height: 1.1;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
