JSFiddle - React, Tailwind, and code Playground

by John Doe

HTML

<div class="prod-wrap">
  <div class="product-list">
  <div class="product-item">
    <div class="product-image-wrap">
      <img class="product-image" src="https://picsum.photos/150?1" />
    </div>
    <span class="product-name">
      Mozaik mintás kék kétfunkciós táska
      <span class="small">
        kék, 10x10x10, Kerek karabínerrel
      </span>
    </span>
    <span class="product-price">
      <span>
        3 490 Ft
      </span>
      <span>
        4 290 Ft
      </span>
      <span class="discount-badge">
        -15 %
      </span>
    </span>
    <span class="product-quantity">
      1 db
    </span>
    <button class="delete-btn">
      <svg xmlns="http://www.w3.org/2000/svg" width="16" height="15" fill="none">
        <path d="M2 3.71423H14" stroke="#A5AAAE" stroke-width="1.5" stroke-linecap="round"></path>
        <path d="M9.28563 2H6.7142C6.24081 2 5.85706 2.38376 5.85706 2.85714V3.71429H10.1428V2.85714C10.1428 2.38376 9.75901 2 9.28563 2Z" stroke="#A5AAAE" stroke-width="1.5"></path>
        <path d="M6.71429 10.9999V6.71423" stroke="#A5AAAE" stroke-width="1.5"></path>
        <path d="M9.28571 10.9999V6.71423" stroke="#A5AAAE" stroke-width="1.5"></path>
        <path d="M11.9228 13.2137C11.886 13.6581 11.5145 14 11.0686 13.9999H4.93199C4.48605 14 4.11457 13.6581 4.07771 13.2137L3.28571 3.71423H12.7143L11.9228 13.2137Z" stroke="#A5AAAE" stroke-width="1.5"></path>
      </svg>
    </button>
  </div>

  <div class="product-item">
    <div class="product-image-wrap">
      <img class="product-image" src="https://picsum.photos/150?2" />
    </div>
    <span class="product-name">Cheeseburger</span>
    <span class="product-price">1800 Ft</span>
    <span class="product-quantity">
      100 db
    </span>
    <button class="delete-btn">
      <svg xmlns="http://www.w3.org/2000/svg" width="16" height="15" fill="none">
        <path d="M2 3.71423H14" stroke="#A5AAAE" stroke-width="1.5"...

CSS

:root {
  --border-radius: .5rem;
  --border-radius-small: .25rem;
}

body{
  background-color: pink;
}

.prod-wrap{
  width: 344px;
  margin: 0 auto;
  background-color: #e2e4fd;
}

*{
  box-sizing: border-box;
  font-size: 1rem;
  font-family: Arial, Helvetica, sans-serif;
}
.product-list {
  display: grid;
  grid-template-columns: min-content max-content max-content min-content min-content;
  gap: 12px;
}

.product-item {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: subgrid;
  gap: 12px;
  width: 100%;
  .product-image-wrap{
    width: 60px;
    height: 60px;
    overflow: hidden;
    .product-image{
      width: 100%; 
      height: 100%; 
      object-fit: cover;
    }
  }
  .product-name{
    display: flex;
    flex-direction: column;
    .small{
      font-size: 12px;
    }
  }
  .discount-badge{
    border-radius: 15%;
    background-color: red;
  }
  .product-price{
    display: flex;
    flex-direction: column;
    gap: .25rem;
  }
  .product-quantity{
    white-space: nowrap;
    .input-number{
      background-color:  #e2e4fd;
      border: 0 solid transparent;
      width: 35px;
      padding: .25rem;
      border-radius: var(--border-radius-small);
    }
  }
  .delete-btn{
    background-color: transparent;
    border: 0;
  }
}